The Two-stage or Miller OTA

Verification

Christian Enz

Swiss Federal Institute of Technology (EPFL), Lausanne, Switzerland

# Initilization¶

# Introduction¶

Schematic of the Miller OTA.

This notebook presents the verification of the two-stage or Miller OTA shown in the above figure and designed in the Design Notebook. In this Notebook, we will first load the process parameters and the specifications. We then will load the bias and the transistors information resulting from the design process to evaluate the theoretical open-loop transfer function to compare it to the simulation results.

# OTA Characteristics¶

## Sizing summary¶

### Process parameters¶

    Main physical parameters:
    ═════════════════════════

$T =$ 300 K
$U_T =$ 25.875 mV

    Main process parameters for TSMC 0.18um:
    ════════════════════════════════════════

$V_{DD} =$ 1.8 V
$C_{ox} =$ 8.443 $\frac{{fF}}{{\mu m^2}}$
$W_{min} =$ 200 nm
$L_{min} =$ 180 nm

    nNMOS parameters:
    ═════════════════
    Long-channel sEKV parameters:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

$n =$ 1.27
$I_{spec\Box} =$ 715 nA
$V_{T0} =$ 455 mV
$L_{sat} =$ 26 nm
$\lambda =$ 20 $\frac{{V}}{{\mu m}}$

    Overlap capacitances:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

$C_{GDo} =$ 0.366 $\frac{{fF}}{{\mu m}}$
$C_{GSo} =$ 0.366 $\frac{{fF}}{{\mu m}}$
$C_{GBo} =$ 0.000 $\frac{{fF}}{{\mu m}}$

    Junction capacitances:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

$C_J =$ 1.000 $\frac{{fF}}{{\mu m^2}}$
$C_{JSW} =$ 0.200 $\frac{{fF}}{{\mu m}}$

    1/f noise parameters:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

$K_F =$ 8.1e-24 J
$AF =$ 1.0
$\rho =$ 5.794e-02 $\frac{{V \cdot m^2}}{{A \cdot s}}$

    Matching parameters:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

$A_{VT} =$ 5 $mV \cdot \mu m$
$A_{\beta} =$ 1 $\% \cdot \mu m$

    Source and drain sheet resistance:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

$R_{sh} =$ 600 $\frac{\Omega}{\mu m}$

    Channel width and length corrections
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

$\Delta W =$ 39 nm
$\Delta L =$ −76 nm

    pNMOS parameters:
    ═════════════════
    Long-channel sEKV parameters:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

$n =$ 1.31
$I_{spec\Box} =$ 173 nA
$V_{T0} =$ 445 mV
$L_{sat} =$ 36 nm
$\lambda =$ 20 $\frac{{V}}{{\mu m}}$

    Overlap capacitances:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

$C_{GDo} =$ 0.329 $\frac{{fF}}{{\mu m}}$
$C_{GSo} =$ 0.329 $\frac{{fF}}{{\mu m}}$
$C_{GBo} =$ 0.000 $\frac{{fF}}{{\mu m}}$

    Junction capacitances:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

$C_J =$ 1.121 $\frac{{fF}}{{\mu m^2}}$
$C_{JSW} =$ 0.248 $\frac{{fF}}{{\mu m}}$

    1/f noise parameters:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

$K_F =$ 6.8e-23 J
$AF =$ 1.0
$\rho =$ 4.828e-01 $\frac{{V \cdot m^2}}{{A \cdot s}}$

    Matching parameters:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

$A_{VT} =$ 5 $mV \cdot \mu m$
$A_{\beta} =$ 1 $\% \cdot \mu m$

    Source and drain sheet resistance:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

$R_{sh} =$ 2386 $\frac{\Omega}{\mu m}$

    Channel width and length corrections
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

$\Delta W =$ 54 nm
$\Delta L =$ −72 nm

### Specifications¶

| Value
--- | ---
Name |
AdcdB | 1.000000e+02
GBWmin | 1.000000e+06
CL | 1.000000e-12
Vosmax | 1.000000e-02
PMdeg | 6.000000e+01

$A_{dc} =$ 100 dB
$GBW =$ 1 MHz
$V_{osmax} =$ 10 mV
$PM =$ 60 deg

### Bias information¶

| Value
--- | ---
Name |
VDD | 1.800000e+00
Ib1 | 1.300000e-07
Ib2 | 2.000000e-06
Cc | 5.000000e-13

$I_{b1} =$ 130 nA
$I_{b2} =$ 2.0 µA
$C_c =$ 500 fF

### Transistors information¶

| Type | Function | W | L | ID | W/L | Ispec | IC | VP-VS | VG-VT0 | ... | CGSe | CGDe | CGBe | CBSe | CBDe | CGS | CGD | CGB | CBS | CBD
--- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | ---
M1a | n | DP | 2.070e-06 | 1.140e-06 | 1.300e-07 | 1.816e+00 | 1.298e-06 | 1.001e-01 | -5.707e-02 | -4.489e-02 | ... | 7.587e-16 | 7.587e-16 | 0 | 3.644e-15 | 3.644e-15 | 2.386e-15 | 7.587e-16 | 3.905e-15 | 4.085e-15 | 3.644e-15
M1b | n | DP | 2.070e-06 | 1.140e-06 | 1.300e-07 | 1.816e+00 | 1.298e-06 | 1.001e-01 | -5.707e-02 | -4.489e-02 | ... | 7.587e-16 | 7.587e-16 | 0 | 3.644e-15 | 3.644e-15 | 2.386e-15 | 7.587e-16 | 3.905e-15 | 4.085e-15 | 3.644e-15
M2 | p | CS | 1.200e-05 | 2.170e-06 | 2.000e-06 | 5.530e+00 | 9.574e-07 | 2.089e+00 | 5.402e-02 | 4.136e-02 | ... | 3.942e-15 | 3.942e-15 | 0 | 3.622e-14 | 3.622e-14 | 9.660e-14 | 3.942e-15 | 2.980e-14 | 6.458e-14 | 3.622e-14
M3a | n | CM | 2.000e-07 | 1.650e-05 | 2.600e-07 | 1.212e-02 | 8.667e-09 | 3.000e+01 | 3.004e-01 | 2.363e-01 | ... | 7.330e-17 | 7.330e-17 | 0 | 9.980e-15 | 9.980e-15 | 1.684e-14 | 7.330e-17 | 2.368e-15 | 1.453e-14 | 9.980e-15
M3b | n | CM | 2.000e-07 | 1.650e-05 | 2.600e-07 | 1.212e-02 | 8.667e-09 | 3.000e+01 | 3.004e-01 | 2.363e-01 | ... | 7.330e-17 | 7.330e-17 | 0 | 9.980e-15 | 9.980e-15 | 1.684e-14 | 7.330e-17 | 2.368e-15 | 1.453e-14 | 9.980e-15
M4a | p | CM | 2.000e-07 | 6.660e-06 | 1.300e-07 | 3.003e-02 | 5.199e-09 | 2.500e+01 | 2.732e-01 | 2.092e-01 | ... | 6.570e-17 | 6.570e-17 | 0 | 4.897e-15 | 4.897e-15 | 6.762e-15 | 6.570e-17 | 1.066e-15 | 6.946e-15 | 4.897e-15
M4b | p | CM | 2.000e-07 | 6.660e-06 | 1.300e-07 | 3.003e-02 | 5.199e-09 | 2.500e+01 | 2.732e-01 | 2.092e-01 | ... | 6.570e-17 | 6.570e-17 | 0 | 4.897e-15 | 4.897e-15 | 6.762e-15 | 6.570e-17 | 1.066e-15 | 6.946e-15 | 4.897e-15
M5a | n | CM | 2.000e-07 | 2.170e-06 | 2.000e-06 | 9.217e-02 | 6.590e-08 | 3.035e+01 | 3.022e-01 | 2.377e-01 | ... | 7.330e-17 | 7.330e-17 | 0 | 1.382e-15 | 1.382e-15 | 2.280e-15 | 7.330e-17 | 3.111e-16 | 1.981e-15 | 1.382e-15
M5b | n | CM | 2.000e-07 | 2.170e-06 | 2.000e-06 | 9.217e-02 | 6.590e-08 | 3.035e+01 | 3.022e-01 | 2.377e-01 | ... | 7.330e-17 | 7.330e-17 | 0 | 1.382e-15 | 1.382e-15 | 2.280e-15 | 7.330e-17 | 3.111e-16 | 1.981e-15 | 1.382e-15

9 rows × 32 columns

## Open-loop gain¶

$A_{dc1} =$ 542
$A_{dc2} =$ 316
$A_{dc} =$ 1.715e+05
$A_{dc1} =$ 54.7 dB
$A_{dc2} =$ 50.0 dB
$A_{dc} =$ 104.7 dB
$C_{GS2} =$ 96.6 fF
$C_{GB2} =$ 29.8 fF
$C_{BD4} =$ 4.9 fF
$C_{BD1} =$ 3.6 fF
$C_{GD1} =$ 758.7 aF
$C_1 =$ 135.7 fF
$C_{BD2} =$ 36.222 fF
$C_{BD5} =$ 1.382 fF
$C_L =$ 1.000 pF
$C_2 =$ 1.038 pF
$GBW =$ 1 MHz (spec)
$GBW = G_{m1}/C_c =$1.152 MHz
$GBW =$ 1.097 MHz (theory)
$f_{p1} =$ 6.7 Hz
$f_{p2} =$ 3.2 MHz
$f_z =$ 9.3 MHz

We can plot the magnitude and phase of the open-loop gain.

    PGBW = −115.719 deg
    PM = 64.281 deg

    findfont: Font family ['cursive'] not found. Falling back to DejaVu Sans.

## Input-referred noise¶

We now can estimate the input-referred noise PSD.

$G_{m1} =$ 3.620 µA/V
$G_{m2} =$ 29.163 µA/V
$G_{m4} =$ 696.227 nA/V
$G_{m5} =$ 10.080 µA/V
$G_{m1}/G_{m4} =$ 5.2
$G_{m2}/G_{m5} =$ 2.893
$2 G_{m1} G_{m2}/G_1^2 =$ 4.7e+06
$\gamma_{n1} =$ 0.653
$\gamma_{n2} =$ 0.763
$\gamma_{n4} =$ 0.831
$\gamma_{n5} =$ 0.812
$\eta_{th} =$ 0.245
$2\gamma_{n1} =$ 1.307
$\gamma_{neq} =$ 1.627
$R_{nth} =$ 449 kOhm
$\sqrt{S_{ninth}} =$ 86.3 $\frac{nV}{\sqrt{Hz}}$
$10 \cdot \log(S_{ninth}) =$ -141.3 $\frac{dBv}{\sqrt{Hz}}$
$(G_{m1}/G_{m4})^2 =$ 27.0
$(G_{m1}/G_1)^2 =$ 2.9e+05
$(G_{m2}/G_{m5})^2 =$ 8.371
$\frac{W_1 \cdot L_1}{W_4 \cdot L_4} =$ 1.8
$\frac{W_1 \cdot L_1}{W_2 \cdot L_2} =$ 9.1e-02
$\frac{W_1 \cdot L_1}{W_5 \cdot L_5} =$ 5.437
$\eta_{fl} =$ 0.546
$f_k =$ 168.9 kHz

We can plot the input-reffered noise

## Input-referred offset voltage¶

The variance of the input-referred offset is given by \begin{equation*} \sigma_{V_{os}}^2 = \sigma_{VT1}^2 + \left(\frac{G_{m3}}{G_{m1}}\right)^2 \cdot \sigma_{VT3}^2 + \left(\frac{I_{b1}}{G_{m1}}\right)^2 \cdot \left(\sigma_{\beta 1}^2 + \sigma_{\beta 3}^2\right) \end{equation*} where \begin{align*} \sigma_{VT1}^2 &= \frac{A_{VTn}^2}{W_1 L_1},\\ \sigma_{\beta 1}^2 &= \frac{A_{\beta n}^2}{W_1 L_1},\\ \sigma_{VT3}^2 &= \frac{A_{VTp}^2}{W_3 L_3},\\ \sigma_{\beta 3}^2 &= \frac{A_{\beta p}^2}{W_3 L_3},\\ \end{align*}

$\sigma_{VT1} =$ 3.255 mV
$\sigma_{VT4} =$ 4.332 mV
$\sqrt{\sigma_{VT1}^2+(G_{m4}/G_{m1})^2\,\sigma_{VT4}^2} =$ 3.360 mV
$\sigma_{\beta1} =$ 0.651 %
$\sigma_{\beta4} =$ 0.866 %
$\sqrt{(I_{b1}/G_{m1})^2\,(\sigma_{\beta1}+\sigma_{\beta4})} =$ 389.215 µV
$\sigma_{Vos} =$ 3.263 mV (contribution of M1a-M1b)
$\sigma_{Vos} =$ 2.307 mV (contribution of M1a only)
$\sigma_{Vos} =$ 889.476 µV (contribution of M4a-M4b)
$\sigma_{Vos} =$ 628.955 µV (contribution of M4a only)
$\sigma_{Vos} =$ 3.382 mV

We see that the random part of the input-referred offset voltage is dominated by the contribution of the differential pair.

## Power consumption¶

The total power consumption (without the current sources) is given by

$I_{tot} =$ 2.260 µA
$P =$ 4.068 µW

We can compare the current and power consumption of the Miller OTA to the telescopic OTA

$I_{telescopic} =$ 500.0 nA
$P_{telescopic} =$ 900.000 nW
$P_{Miller}/P_{telescopic} =$ 4.5

The current and power consumption of the Miller OTA is 4.5 times larger than that of the telescopic OTA for the same specifications and performance.

# Simulation results from Smash¶

## Saving parameter file¶

We first write the parameter file for this specific design for running the Smash simulations.

    .param VDD=1.8 Vic=0.9 Vos=0.000u Ib1=130n Ib2=2.0u
    .param CL=1p Cc=0.5p
    .param W1=2.070u L1=1.140u W2=12.000u L2=2.170u W3=0.200u L3=16.500u W4=0.200u L4=6.660u W5=0.200u L5=2.170u

## Operating point¶

To start we need to check the quiescent voltages and currents and the operating points of all transistors by running a .OP simulation.

    Starting Smash simulation...

    ----------------------------------------------------------------------
    -
    - SMASH (TM) release 7.6.0 (64-bit) of Jun 30 2020
    - Copyright (c) Dolphin Design, 1992-2020. All Rights Reserved.
    -
    ----------------------------------------------------------------------

    Output directory L:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Miller OTA (VS)\M2 in MI\Simulations\smash\Gain
    Parsing circuit l:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Miller OTA (VS)\M2 in MI\Simulations\smash\Gain\Miller_OTA.pat
    Loading circuit l:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Miller OTA (VS)\M2 in MI\Simulations\smash\Gain\Miller_OTA.pat
    Processing top-level
    Elaborating circuit...
    Elaborating circuit (creating devices)...
    Elaborating circuit (elaborating devices)...
    Elaborating circuit (logic)...
    Elaborating circuit (creating devices)...
    Elaborating circuit (elaborating devices)...
    Initializing...
    Searching for HZ nets: 0%
    Linking analog resolution matrix...
    Load completed.
    Operating Point
    Operating-Point analysis (trying logarithmic damping heuristics)...
    Iteration    1, residual  9.000e-01 on EINP
    Iteration    2, residual  6.697e-01 on EINP
    Iteration    3, residual  4.657e-01 on EINP
    Iteration    4, residual  2.924e-01 on EINP
    Iteration    5, residual  1.557e-01 on EINP
    Iteration    6, residual  6.180e-02 on EINP
    Iteration    7, residual  1.368e-02 on EINP
    Iteration    8, residual  5.013e-03 on VDD
    Iteration    9, residual  2.206e-03 on VDD
    Iteration   10, residual  6.037e-04 on VDD
    Iteration   11, residual  6.013e-05 on VDD
    Iteration   12, residual  6.763e-07 on VDD
    Iteration   13, residual  3.131e-08 on M1B::SI
    Iteration   14, residual  3.306e-09 on M1B::SI
    Iteration   15, residual  4.856e-11 on M1B::SI
    Iteration   16, residual  1.090e-14 on M1B::SI

    Operating point analysis completed (converged)

    CPU Time:     1s 250ms
    Elapsed Time: 10s 898ms 778us

We can check the operating point information looking the .op file.

    Contents of the op file:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

    * ----------------------------------------------------------------------
    * Operating point information at 27 degC
    * ----------------------------------------------------------------------
    *
    * Initial state obtained by resetting everything to zero
    *
    * Convergence obtained with initial logarithmic damping heuristics
    * Number of iterations: 16
    *
    * Minimum parallel DC conductance          (.GMINDC   ): 1e-12
    * Minimum parallel transient conductance   (.GMIN     ): 1e-12
    * Minimum capacitance on analog nets       (.CAPAMIN  ): 0
    *
    * ----------------------------------------------------------------------

    * ----------------------------------------------------------------------
    * Analog nets
    * ----------------------------------------------------------------------

    Nets:

        1        =  1.0069281e+00 V.
        3        =  3.9400665e-01 V.
        4        =  1.0069281e+00 V.
        5        =  8.2257555e-01 V.
        6        =  8.3638641e-01 V.
        IC       =  9.0000000e-01 V.
        ID       =  0.0000000e+00 V.
        INN      =  9.0000000e-01 V.
        INP      =  9.0000000e-01 V.
        OUT      =  1.7845055e+00 V.
        VDD      =  1.8000000e+00 V.

    Spice internal nets:

        M1A::DI  =  1.0069208e+00 V.
        M1A::SI  =  3.9401403e-01 V.
        M1B::DI  =  1.0069208e+00 V.
        M1B::SI  =  3.9401403e-01 V.
        M2::DI   =  1.7845853e+00 V.
        M2::SI   =  1.7999202e+00 V.
        M3A::DI  =  8.2244501e-01 V.
        M3A::SI  =  1.3054352e-04 V.
        M3B::DI  =  3.9387633e-01 V.
        M3B::SI  =  1.3031521e-04 V.
        M4A::DI  =  1.0071719e+00 V.
        M4A::SI  =  1.7997562e+00 V.
        M4B::DI  =  1.0071719e+00 V.
        M4B::SI  =  1.7997562e+00 V.
        M5A::DI  =  8.3538222e-01 V.
        M5A::SI  =  1.0041837e-03 V.
        M5B::DI  =  1.7834933e+00 V.
        M5B::SI  =  1.0122420e-03 V.

    Voltage sources:

        VDD   =  1.8000000e+00 V, -4.5355981e-06 A,  8.164e-06 W.
        VIC   =  9.0000000e-01 V,  0.0000000e+00 A,  0.000e+00 W.
        VID   =  0.0000000e+00 V,  0.0000000e+00 A,  0.000e+00 W.
        EINP  =  0.0000000e+00 V,  0.0000000e+00 A,  0.000e+00 W.
        EINN  =  0.0000000e+00 V,  0.0000000e+00 A,  0.000e+00 W.

    Current sources:

    *   IB1  =  2.6000000e-07  A,  9.7742445e-01  V,  2.541e-07 W.
    *   IB2  =  2.0000000e-06  A,  9.6361359e-01  V,  1.927e-06 W.

    END_USE_OP_TAG

    * ----------------------------------------------------------------------
    * SPICE Dissipated power
    * ----------------------------------------------------------------------

        Total SPICE power    = 5.9914048e-06 W.

    * ----------------------------------------------------------------------
    * (C) Capacitors
    * ----------------------------------------------------------------------

    CL (DEFAULT, multiplicity = 1)
               VALUE = 1e-12            ,           POWER = 0                ,

    CC (DEFAULT, multiplicity = 1)
               VALUE = 5e-13            ,           POWER = -0               ,

    * ----------------------------------------------------------------------
    * (M) Mos transistors
    * ----------------------------------------------------------------------

    OFF:    0
    SUB:    2
    LIN:    1
    SAT:    6

    M1A (NMOS, type NMOS, model EKV 2.6, region SUB (saturation - weak inversion), multiplicity = 1):
      Vds  =  6.12907e-01,  Vgs  =  5.05986e-01,  Vbs  = -3.94014e-01
                WEFF = 2.109e-06        ,            LEFF = 1.064e-06        ,           POWER = 7.95417e-08      ,              ID = 1.29772e-07      ,
                  GM = 3.69087e-06      ,             GDS = 6.24013e-09      ,            GMBS = 8.85535e-07      ,           VDSAT = 0.119796         ,
                 VTH = 0.579306         ,          DELVTO = 0               D,              QD = -1.93309e-17     ,              QG = 1.18031e-14      ,
                  QB = -1.17459e-14     ,              QS = -3.78435e-17     ,             CGG = 4.89025e-15      ,             CGD = 5.00961e-18      ,
                 CGS = -1.54489e-15     ,             CGB = -3.35038e-15     ,             CBG = -3.34195e-15     ,             CBD = -3.41475e-18     ,
                 CBS = -3.67605e-16     ,             CBB = 3.71297e-15      ,             CDG = -5.30242e-16     ,             CDD = -5.46186e-19     ,
                 CDS = 6.54945e-16      ,             CDB = -1.24157e-16     ,            QBDJ = 2.68595e-15      ,            QBSJ = 1.11238e-15      ,
                CBDJ = 1.54323e-15      ,            CBSJ = 1.69061e-15      ,

    M1B (NMOS, type NMOS, model EKV 2.6, region SUB (saturation - weak inversion), multiplicity = 1):
      Vds  =  6.12907e-01,  Vgs  =  5.05986e-01,  Vbs  = -3.94014e-01
                WEFF = 2.109e-06        ,            LEFF = 1.064e-06        ,           POWER = 7.95417e-08      ,              ID = 1.29772e-07      ,
                  GM = 3.69087e-06      ,             GDS = 6.24013e-09      ,            GMBS = 8.85535e-07      ,           VDSAT = 0.119796         ,
                 VTH = 0.579306         ,          DELVTO = 0               D,              QD = -1.93309e-17     ,              QG = 1.18031e-14      ,
                  QB = -1.17459e-14     ,              QS = -3.78435e-17     ,             CGG = 4.89025e-15      ,             CGD = 5.00961e-18      ,
                 CGS = -1.54489e-15     ,             CGB = -3.35038e-15     ,             CBG = -3.34195e-15     ,             CBD = -3.41475e-18     ,
                 CBS = -3.67605e-16     ,             CBB = 3.71297e-15      ,             CDG = -5.30242e-16     ,             CDD = -5.46186e-19     ,
                 CDS = 6.54945e-16      ,             CDB = -1.24157e-16     ,            QBDJ = 2.68595e-15      ,            QBSJ = 1.11238e-15      ,
                CBDJ = 1.54323e-15      ,            CBSJ = 1.69061e-15      ,

    M2 (PMOS, type PMOS, model EKV 2.6, region LIN (linear - strong inversion), multiplicity = 1):
      Vds  = -1.53349e-02,  Vgs  = -7.92992e-01,  Vbs  =  7.97991e-05
                WEFF = 1.2054e-05       ,            LEFF = 2.098e-06        ,           POWER = 3.12376e-08      ,              ID = -2.01605e-06     ,
                  GM = 5.78229e-06      ,             GDS = 0.000127333      ,            GMBS = 2.43279e-06      ,           VDSAT = -0.344478        ,
                 VTH = -0.469252        ,          DELVTO = 0               D,              QD = 2.83167e-14      ,              QG = -1.89711e-13     ,
                  QB = 1.32458e-13      ,              QS = 2.89364e-14      ,             CGG = 1.95525e-13      ,             CGD = -9.29756e-14     ,
                 CGS = -9.73269e-14     ,             CGB = -5.22208e-15     ,             CBG = -9.21385e-15     ,             CBD = -2.54039e-14     ,
                 CBS = -2.65919e-14     ,             CBB = 6.12096e-14      ,             CDG = -9.30631e-14     ,             CDD = 7.93143e-14      ,
                 CDS = 4.16905e-14      ,             CDB = -2.79418e-14     ,            QBDJ = -1.98542e-16     ,            QBSJ = -1.03144e-18     ,
                CBDJ = 1.15032e-14      ,            CBSJ = 1.15843e-14      ,

    M3A (NMOS, type NMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  =  8.22314e-01,  Vgs  =  8.22445e-01,  Vbs  = -1.30544e-04
                WEFF = 2.39e-07         ,            LEFF = 1.6424e-05       ,           POWER = 2.1387e-07       ,              ID = 2.59998e-07      ,
                  GM = 1.28689e-06      ,             GDS = 4.18347e-10      ,            GMBS = 3.72401e-07      ,           VDSAT = 0.380543         ,
                 VTH = 0.457155         ,          DELVTO = 0               D,              QD = -2.57372e-15     ,              QG = 2.55927e-14      ,
                  QB = -1.89501e-14     ,              QS = -4.06885e-15     ,             CGG = 2.25034e-14      ,             CGD = 1.5471e-18       ,
                 CGS = -1.99392e-14     ,             CGB = -2.56579e-15     ,             CBG = -2.99868e-15     ,             CBD = -2.03217e-19     ,
                 CBS = -4.75136e-15     ,             CBB = 7.75024e-15      ,             CDG = -7.75406e-15     ,             CDD = -5.34254e-19     ,
                 CDS = 9.81064e-15      ,             CDB = -2.05605e-15     ,            QBDJ = 4.35614e-16      ,            QBSJ = 7.4219e-20       ,
                CBDJ = 3.14865e-16      ,            CBSJ = 3.56396e-16      ,

    M3B (NMOS, type NMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  =  3.93746e-01,  Vgs  =  8.22445e-01,  Vbs  = -1.30315e-04
                WEFF = 2.39e-07         ,            LEFF = 1.6424e-05       ,           POWER = 1.02262e-07      ,              ID = 2.59544e-07      ,
                  GM = 1.27924e-06      ,             GDS = 8.5883e-09       ,            GMBS = 3.70459e-07      ,           VDSAT = 0.38052          ,
                 VTH = 0.457183         ,          DELVTO = 0               D,              QD = -2.57718e-15     ,              QG = 2.55958e-14      ,
                  QB = -1.89491e-14     ,              QS = -4.06956e-15     ,             CGG = 2.26118e-14      ,             CGD = -1.44022e-16     ,
                 CGS = -1.9928e-14      ,             CGB = -2.53973e-15     ,             CBG = -2.97306e-15     ,             CBD = -3.4968e-17      ,
                 CBS = -4.74875e-15     ,             CBB = 7.75678e-15      ,             CDG = -7.85816e-15     ,             CDD = 1.39116e-16      ,
                 CDS = 9.80041e-15      ,             CDB = -2.08136e-15     ,            QBDJ = 2.15193e-16      ,            QBSJ = 7.40892e-20      ,
                CBDJ = 3.31152e-16      ,            CBSJ = 3.56396e-16      ,

    M4A (PMOS, type PMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  = -7.92584e-01,  Vgs  = -7.92828e-01,  Vbs  =  2.43769e-04
                WEFF = 2.54e-07         ,            LEFF = 6.588e-06        ,           POWER = 1.0292e-07       ,              ID = -1.29772e-07     ,
                  GM = 6.88033e-07      ,             GDS = 4.0614e-10       ,            GMBS = 2.42721e-07      ,           VDSAT = -0.350513        ,
                 VTH = -0.460859        ,          DELVTO = 0               D,              QD = 9.83729e-16      ,              QG = -1.1605e-14      ,
                  QB = 9.05713e-15      ,              QS = 1.56416e-15      ,             CGG = 9.62116e-15      ,             CGD = 8.20774e-19      ,
                 CGS = -8.37941e-15     ,             CGB = -1.24257e-15     ,             CBG = -1.42542e-15     ,             CBD = -1.20127e-19     ,
                 CBS = -2.28199e-15     ,             CBB = 3.70753e-15      ,             CDG = -3.25351e-15     ,             CDD = -2.78137e-19     ,
                 CDS = 4.22994e-15      ,             CDB = -9.76155e-16     ,            QBDJ = -3.38936e-16     ,            QBSJ = -1.19235e-19     ,
                CBDJ = 3.42005e-16      ,            CBSJ = 4.38362e-16      ,

    M4B (PMOS, type PMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  = -7.92584e-01,  Vgs  = -7.92828e-01,  Vbs  =  2.43769e-04
                WEFF = 2.54e-07         ,            LEFF = 6.588e-06        ,           POWER = 1.0292e-07       ,              ID = -1.29772e-07     ,
                  GM = 6.88033e-07      ,             GDS = 4.0614e-10       ,            GMBS = 2.42721e-07      ,           VDSAT = -0.350513        ,
                 VTH = -0.460859        ,          DELVTO = 0               D,              QD = 9.83729e-16      ,              QG = -1.1605e-14      ,
                  QB = 9.05713e-15      ,              QS = 1.56416e-15      ,             CGG = 9.62116e-15      ,             CGD = 8.20774e-19      ,
                 CGS = -8.37941e-15     ,             CGB = -1.24257e-15     ,             CBG = -1.42542e-15     ,             CBD = -1.20127e-19     ,
                 CBS = -2.28199e-15     ,             CBB = 3.70753e-15      ,             CDG = -3.25351e-15     ,             CDD = -2.78137e-19     ,
                 CDS = 4.22994e-15      ,             CDB = -9.76155e-16     ,            QBDJ = -3.38936e-16     ,            QBSJ = -1.19235e-19     ,
                CBDJ = 3.42005e-16      ,            CBSJ = 4.38362e-16      ,

    M5A (NMOS, type NMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  =  8.34378e-01,  Vgs  =  8.35382e-01,  Vbs  = -1.00418e-03
                WEFF = 2.39e-07         ,            LEFF = 2.094e-06        ,           POWER = 1.67277e-06      ,              ID = 2e-06            ,
                  GM = 9.71543e-06      ,             GDS = 2.43046e-08      ,            GMBS = 2.79676e-06      ,           VDSAT = 0.376849         ,
                 VTH = 0.469882         ,          DELVTO = 0               D,              QD = -3.28713e-16     ,              QG = 3.26557e-15      ,
                  QB = -2.41722e-15     ,              QS = -5.19631e-16     ,             CGG = 2.87202e-15      ,             CGD = 1.544e-18        ,
                 CGS = -2.54081e-15     ,             CGB = -3.32759e-16     ,             CBG = -3.82469e-16     ,             CBD = -2.02676e-19     ,
                 CBS = -6.0581e-16      ,             CBB = 9.88482e-16      ,             CDG = -9.89735e-16     ,             CDD = -5.3325e-19      ,
                 CDS = 1.25031e-15      ,             CDB = -2.60047e-16     ,            QBDJ = 4.42108e-16      ,            QBSJ = 5.70856e-19      ,
                CBDJ = 3.1447e-16       ,            CBSJ = 3.56319e-16      ,

    M5B (NMOS, type NMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  =  1.78248e+00,  Vgs  =  8.35374e-01,  Vbs  = -1.01224e-03
                WEFF = 2.39e-07         ,            LEFF = 2.094e-06        ,           POWER = 3.59765e-06      ,              ID = 2.01605e-06      ,
                  GM = 9.79045e-06      ,             GDS = 1.27146e-08      ,            GMBS = 2.81728e-06      ,           VDSAT = 0.377167         ,
                 VTH = 0.469483         ,          DELVTO = 0               D,              QD = -3.29157e-16     ,              QG = 3.26686e-15      ,
                  QB = -2.4174e-15      ,              QS = -5.20303e-16     ,             CGG = 2.87267e-15      ,             CGD = 1.25391e-18      ,
                 CGS = -2.54115e-15     ,             CGB = -3.32777e-16     ,             CBG = -3.82467e-16     ,             CBD = -1.64558e-19     ,
                 CBS = -6.05805e-16     ,             CBB = 9.88437e-16      ,             CDG = -9.90008e-16     ,             CDD = -4.33083e-19     ,
                 CDS = 1.25047e-15      ,             CDB = -2.60025e-16     ,            QBDJ = 9.00334e-16      ,            QBSJ = 5.75436e-19      ,
                CBDJ = 2.93622e-16      ,            CBSJ = 3.56318e-16      ,

    * ----------------------------------------------------------------------
    * (R) Resistors
    * ----------------------------------------------------------------------

Looking at the .op file, we see that, as expected, the quiescent output voltage $V_{outq}$

$V_{outq} =$ 1.785 V

It is too high pushing M2 out of saturation.

We can extract the differential input voltage that needs to be applied at the input to bring the output in the high gain region setting it for example at the input common-mode $V_{ic}=0.9\,V$. This can be done by connecting the OTA in a voltage follower mode. The input-referred offset voltage can be extracted from the closed-loop voltage follower circuit as \begin{equation*} V_{os} = V_{in} - \left(1+\frac{1}{A}\right) \cdot V_{out} \cong V_{in} - V_{out} \quad \textsf{for $A \gg 1$}, \end{equation*} where $A \triangleq A_{open\textsf{-}loop}(0)$ is the open-loop DC gain which can be assumed to be much larger than 1. This means that, provided the DC open-loop gain is sufficiently large, the offset voltage can be measured at the amplifier differential input after imposing the proper input common-mode voltage $V_{ic}$.

We can now simulate the OTA in closed-loop as a voltage follower.

    .param VDD=1.8 Vic=0.9 Ib1=130n Ib2=2.0u
    .param CL=1p Cc=0.5p
    .param W1=2.070u L1=1.140u W2=12.000u L2=2.170u W3=0.200u L3=16.500u W4=0.200u L4=6.660u W5=0.200u L5=2.170u

    Starting Smash simulation...

    ----------------------------------------------------------------------
    -
    - SMASH (TM) release 7.6.0 (64-bit) of Jun 30 2020
    - Copyright (c) Dolphin Design, 1992-2020. All Rights Reserved.
    -
    ----------------------------------------------------------------------

    Output directory L:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Miller OTA (VS)\M2 in MI\Simulations\smash\Follower
    Parsing circuit l:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Miller OTA (VS)\M2 in MI\Simulations\smash\Follower\Miller_OTA.pat
    Loading circuit l:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Miller OTA (VS)\M2 in MI\Simulations\smash\Follower\Miller_OTA.pat
    Processing top-level
    Elaborating circuit...
    Elaborating circuit (creating devices)...
    Elaborating circuit (elaborating devices)...
    Elaborating circuit (logic)...
    Elaborating circuit (creating devices)...
    Elaborating circuit (elaborating devices)...
    Initializing...
    Searching for HZ nets: 0%
    Linking analog resolution matrix...
    Load completed.
    Operating Point
    Operating-Point analysis (trying logarithmic damping heuristics)...
    Iteration    1, residual  4.739e-02 on VDD
    Iteration    2, residual  3.964e-02 on VDD
    Iteration    3, residual  3.233e-02 on VDD
    Iteration    4, residual  2.552e-02 on VDD
    Iteration    5, residual  1.925e-02 on VDD
    Iteration    6, residual  1.370e-02 on VDD
    Iteration    7, residual  8.898e-03 on VDD
    Iteration    8, residual  5.010e-03 on VDD
    Iteration    9, residual  2.204e-03 on VDD
    Iteration   10, residual  6.027e-04 on VDD
    Iteration   11, residual  5.998e-05 on VDD
    Iteration   12, residual  3.355e-06 on M1A::SI
    Iteration   13, residual  1.371e-06 on M1A::SI
    Iteration   14, residual  5.259e-07 on M1A::SI
    Iteration   15, residual  1.840e-07 on M1A::SI
    Iteration   16, residual  5.167e-08 on M1A::SI
    Iteration   17, residual  8.105e-09 on M1A::SI
    Iteration   18, residual  2.939e-10 on M1A::DI
    Iteration   19, residual  4.222e-13 on M1A::DI

    Operating point analysis completed (converged)
    Launch Measurements: 13
    End Measurements

    CPU Time:     1s 62ms 500us
    Elapsed Time: 7s 702ms 999us

Let's have a look at the operating point information.

    Contents of the op file:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

    * ----------------------------------------------------------------------
    * Operating point information at 27 degC
    * ----------------------------------------------------------------------
    *
    * Initial state obtained by resetting everything to zero
    *
    * Convergence obtained with initial logarithmic damping heuristics
    * Number of iterations: 19
    *
    * Minimum parallel DC conductance          (.GMINDC   ): 1e-12
    * Minimum parallel transient conductance   (.GMIN     ): 1e-12
    * Minimum capacitance on analog nets       (.CAPAMIN  ): 0
    *
    * ----------------------------------------------------------------------

    * ----------------------------------------------------------------------
    * Analog nets
    * ----------------------------------------------------------------------

    Nets:

        1        =  1.2643850e+00 V.
        3        =  3.9434409e-01 V.
        4        =  1.0068446e+00 V.
        5        =  8.2257555e-01 V.
        6        =  8.3638641e-01 V.
        INP      =  9.0000000e-01 V.
        OUT      =  9.0043467e-01 V.
        VDD      =  1.8000000e+00 V.

    Spice internal nets:

        M1A::DI  =  1.0068372e+00 V.
        M1A::SI  =  3.9435147e-01 V.
        M1B::DI  =  1.2643776e+00 V.
        M1B::SI  =  3.9435147e-01 V.
        M2::DI   =  9.0051389e-01 V.
        M2::SI   =  1.7999208e+00 V.
        M3A::DI  =  8.2244501e-01 V.
        M3A::SI  =  1.3054352e-04 V.
        M3B::DI  =  3.9421377e-01 V.
        M3B::SI  =  1.3031666e-04 V.
        M4A::DI  =  1.0070884e+00 V.
        M4A::SI  =  1.7997561e+00 V.
        M4B::DI  =  1.2646287e+00 V.
        M4B::SI  =  1.7997563e+00 V.
        M5A::DI  =  8.3538222e-01 V.
        M5A::SI  =  1.0041837e-03 V.
        M5B::DI  =  8.9942974e-01 V.
        M5B::SI  =  1.0049342e-03 V.

    Voltage sources:

        VDD  =  1.8000000e+00 V, -4.5210457e-06 A,  8.138e-06 W.
        VIN  =  9.0000000e-01 V,  0.0000000e+00 A,  0.000e+00 W.

    Current sources:

    *   IB1  =  2.6000000e-07  A,  9.7742445e-01  V,  2.541e-07 W.
    *   IB2  =  2.0000000e-06  A,  9.6361359e-01  V,  1.927e-06 W.

    END_USE_OP_TAG

    * ----------------------------------------------------------------------
    * SPICE Dissipated power
    * ----------------------------------------------------------------------

        Total SPICE power    = 5.9651473e-06 W.

    * ----------------------------------------------------------------------
    * (C) Capacitors
    * ----------------------------------------------------------------------

    CL (DEFAULT, multiplicity = 1)
               VALUE = 1e-12            ,           POWER = 0                ,

    CC (DEFAULT, multiplicity = 1)
               VALUE = 5e-13            ,           POWER = 0                ,

    * ----------------------------------------------------------------------
    * (M) Mos transistors
    * ----------------------------------------------------------------------

    OFF:    0
    SUB:    2
    LIN:    0
    SAT:    7

    M1A (NMOS, type NMOS, model EKV 2.6, region SUB (saturation - weak inversion), multiplicity = 1):
      Vds  =  6.12486e-01,  Vgs  =  5.06083e-01,  Vbs  = -3.94351e-01
                WEFF = 2.109e-06        ,            LEFF = 1.064e-06        ,           POWER = 7.95223e-08      ,              ID = 1.2983e-07       ,
                  GM = 3.69244e-06      ,             GDS = 6.24475e-09      ,            GMBS = 8.85789e-07      ,           VDSAT = 0.119801         ,
                 VTH = 0.579382         ,          DELVTO = 0               D,              QD = -1.93404e-17     ,              QG = 1.18047e-14      ,
                  QB = -1.17475e-14     ,              QS = -3.78616e-17     ,             CGG = 4.89044e-15      ,             CGD = 5.01058e-18      ,
                 CGS = -1.54557e-15     ,             CGB = -3.34988e-15     ,             CBG = -3.34145e-15     ,             CBD = -3.41478e-18     ,
                 CBS = -3.67716e-16     ,             CBB = 3.71258e-15      ,             CDG = -5.30482e-16     ,             CDD = -5.46517e-19     ,
                 CDS = 6.55225e-16      ,             CDB = -1.24196e-16     ,            QBDJ = 2.68574e-15      ,            QBSJ = 1.11329e-15      ,
                CBDJ = 1.54325e-15      ,            CBSJ = 1.6905e-15       ,

    M1B (NMOS, type NMOS, model EKV 2.6, region SUB (saturation - weak inversion), multiplicity = 1):
      Vds  =  8.70026e-01,  Vgs  =  5.05649e-01,  Vbs  = -3.94351e-01
                WEFF = 2.109e-06        ,            LEFF = 1.064e-06        ,           POWER = 1.12862e-07      ,              ID = 1.29717e-07      ,
                  GM = 3.69108e-06      ,             GDS = 5.41004e-09      ,            GMBS = 8.85364e-07      ,           VDSAT = 0.119759         ,
                 VTH = 0.57912          ,          DELVTO = 0               D,              QD = -1.92465e-17     ,              QG = 1.18038e-14      ,
                  QB = -1.17469e-14     ,              QS = -3.76813e-17     ,             CGG = 4.88573e-15      ,             CGD = 4.71188e-18      ,
                 CGS = -1.5391e-15      ,             CGB = -3.35134e-15     ,             CBG = -3.34308e-15     ,             CBD = -3.2159e-18      ,
                 CBS = -3.66221e-16     ,             CBB = 3.71252e-15      ,             CDG = -5.28252e-16     ,             CDD = -5.12273e-19     ,
                 CDS = 6.52426e-16      ,             CDB = -1.23661e-16     ,            QBDJ = 3.31091e-15      ,            QBSJ = 1.11329e-15      ,
                CBDJ = 1.50148e-15      ,            CBSJ = 1.6905e-15       ,

    M2 (PMOS, type PMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  = -8.99407e-01,  Vgs  = -5.35536e-01,  Vbs  =  7.92229e-05
                WEFF = 1.2054e-05       ,            LEFF = 2.098e-06        ,           POWER = 1.80048e-06      ,              ID = -2.00149e-06     ,
                  GM = 2.83857e-05      ,             GDS = 2.16276e-08      ,            GMBS = 9.49804e-06      ,           VDSAT = -0.178326        ,
                 VTH = -0.469015        ,          DELVTO = 0               D,              QD = 3.16211e-15      ,              QG = -1.39138e-13     ,
                  QB = 1.30471e-13      ,              QS = 5.50553e-15      ,             CGG = 1.18863e-13      ,             CGD = 2.82417e-17      ,
                 CGS = -9.02265e-14     ,             CGB = -2.86645e-14     ,             CBG = -2.94881e-14     ,             CBD = -6.93255e-18     ,
                 CBS = -2.69063e-14     ,             CBB = 5.64014e-14      ,             CDG = -3.40244e-14     ,             CDD = -8.11225e-18     ,
                 CDS = 4.45766e-14      ,             CDB = -1.05441e-14     ,            QBDJ = -9.93957e-15     ,            QBSJ = -1.024e-18       ,
                CBDJ = 8.6938e-15       ,            CBSJ = 1.15843e-14      ,

    M3A (NMOS, type NMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  =  8.22314e-01,  Vgs  =  8.22445e-01,  Vbs  = -1.30544e-04
                WEFF = 2.39e-07         ,            LEFF = 1.6424e-05       ,           POWER = 2.1387e-07       ,              ID = 2.59998e-07      ,
                  GM = 1.28689e-06      ,             GDS = 4.18347e-10      ,            GMBS = 3.72401e-07      ,           VDSAT = 0.380543         ,
                 VTH = 0.457155         ,          DELVTO = 0               D,              QD = -2.57372e-15     ,              QG = 2.55927e-14      ,
                  QB = -1.89501e-14     ,              QS = -4.06885e-15     ,             CGG = 2.25034e-14      ,             CGD = 1.5471e-18       ,
                 CGS = -1.99392e-14     ,             CGB = -2.56579e-15     ,             CBG = -2.99868e-15     ,             CBD = -2.03217e-19     ,
                 CBS = -4.75136e-15     ,             CBB = 7.75024e-15      ,             CDG = -7.75406e-15     ,             CDD = -5.34254e-19     ,
                 CDS = 9.81064e-15      ,             CDB = -2.05605e-15     ,            QBDJ = 4.35614e-16      ,            QBSJ = 7.4219e-20       ,
                CBDJ = 3.14865e-16      ,            CBSJ = 3.56396e-16      ,

    M3B (NMOS, type NMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  =  3.94083e-01,  Vgs  =  8.22445e-01,  Vbs  = -1.30317e-04
                WEFF = 2.39e-07         ,            LEFF = 1.6424e-05       ,           POWER = 1.02351e-07      ,              ID = 2.59547e-07      ,
                  GM = 1.27932e-06      ,             GDS = 8.49268e-09      ,            GMBS = 3.70479e-07      ,           VDSAT = 0.38052          ,
                 VTH = 0.457183         ,          DELVTO = 0               D,              QD = -2.57713e-15     ,              QG = 2.55958e-14      ,
                  QB = -1.89491e-14     ,              QS = -4.06955e-15     ,             CGG = 2.26104e-14      ,             CGD = -1.42215e-16     ,
                 CGS = -1.99281e-14     ,             CGB = -2.54005e-15     ,             CBG = -2.97338e-15     ,             CBD = -3.45374e-17     ,
                 CBS = -4.74879e-15     ,             CBB = 7.7567e-15       ,             CDG = -7.85688e-15     ,             CDD = 1.37386e-16      ,
                 CDS = 9.80054e-15      ,             CDB = -2.08105e-15     ,            QBDJ = 2.15371e-16      ,            QBSJ = 7.40901e-20      ,
                CBDJ = 3.31136e-16      ,            CBSJ = 3.56396e-16      ,

    M4A (PMOS, type PMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  = -7.92668e-01,  Vgs  = -7.92912e-01,  Vbs  =  2.43877e-04
                WEFF = 2.54e-07         ,            LEFF = 6.588e-06        ,           POWER = 1.02976e-07      ,              ID = -1.2983e-07      ,
                  GM = 6.88185e-07      ,             GDS = 4.06303e-10      ,            GMBS = 2.42778e-07      ,           VDSAT = -0.350572        ,
                 VTH = -0.460859        ,          DELVTO = 0               D,              QD = 9.84001e-16      ,              QG = -1.16058e-14     ,
                  QB = 9.05725e-15      ,              QS = 1.56458e-15      ,             CGG = 9.62134e-15      ,             CGD = 8.20792e-19      ,
                 CGS = -8.37967e-15     ,             CGB = -1.24249e-15     ,             CBG = -1.42537e-15     ,             CBD = -1.20124e-19     ,
                 CBS = -2.282e-15       ,             CBB = 3.70749e-15      ,             CDG = -3.25361e-15     ,             CDD = -2.78147e-19     ,
                 CDS = 4.23006e-15      ,             CDB = -9.76177e-16     ,            QBDJ = -3.38968e-16     ,            QBSJ = -1.19288e-19     ,
                CBDJ = 3.41998e-16      ,            CBSJ = 4.38362e-16      ,

    M4B (PMOS, type PMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  = -5.35128e-01,  Vgs  = -7.92912e-01,  Vbs  =  2.43667e-04
                WEFF = 2.54e-07         ,            LEFF = 6.588e-06        ,           POWER = 6.94797e-08      ,              ID = -1.29718e-07     ,
                  GM = 6.87595e-07      ,             GDS = 4.64232e-10      ,            GMBS = 2.42574e-07      ,           VDSAT = -0.350556        ,
                 VTH = -0.460879        ,          DELVTO = 0               D,              QD = 9.83929e-16      ,              QG = -1.16056e-14     ,
                  QB = 9.05722e-15      ,              QS = 1.56446e-15      ,             CGG = 9.62128e-15      ,             CGD = 8.04047e-19      ,
                 CGS = -8.3796e-15      ,             CGB = -1.24249e-15     ,             CBG = -1.42535e-15     ,             CBD = -1.52383e-19     ,
                 CBS = -2.282e-15       ,             CBB = 3.7075e-15       ,             CDG = -3.25362e-15     ,             CDD = -2.19114e-19     ,
                 CDS = 4.23002e-15      ,             CDB = -9.76188e-16     ,            QBDJ = -2.37533e-16     ,            QBSJ = -1.19186e-19     ,
                CBDJ = 3.64873e-16      ,            CBSJ = 4.38362e-16      ,

    M5A (NMOS, type NMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  =  8.34378e-01,  Vgs  =  8.35382e-01,  Vbs  = -1.00418e-03
                WEFF = 2.39e-07         ,            LEFF = 2.094e-06        ,           POWER = 1.67277e-06      ,              ID = 2e-06            ,
                  GM = 9.71543e-06      ,             GDS = 2.43046e-08      ,            GMBS = 2.79676e-06      ,           VDSAT = 0.376849         ,
                 VTH = 0.469882         ,          DELVTO = 0               D,              QD = -3.28713e-16     ,              QG = 3.26557e-15      ,
                  QB = -2.41722e-15     ,              QS = -5.19631e-16     ,             CGG = 2.87202e-15      ,             CGD = 1.544e-18        ,
                 CGS = -2.54081e-15     ,             CGB = -3.32759e-16     ,             CBG = -3.82469e-16     ,             CBD = -2.02676e-19     ,
                 CBS = -6.0581e-16      ,             CBB = 9.88482e-16      ,             CDG = -9.89735e-16     ,             CDD = -5.3325e-19      ,
                 CDS = 1.25031e-15      ,             CDB = -2.60047e-16     ,            QBDJ = 4.42108e-16      ,            QBSJ = 5.70856e-19      ,
                CBDJ = 3.1447e-16       ,            CBSJ = 3.56319e-16      ,

    M5B (NMOS, type NMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  =  8.98425e-01,  Vgs  =  8.35381e-01,  Vbs  = -1.00493e-03
                WEFF = 2.39e-07         ,            LEFF = 2.094e-06        ,           POWER = 1.80222e-06      ,              ID = 2.00149e-06      ,
                  GM = 9.72298e-06      ,             GDS = 2.27101e-08      ,            GMBS = 2.79885e-06      ,           VDSAT = 0.376872         ,
                 VTH = 0.469853         ,          DELVTO = 0               D,              QD = -3.28746e-16     ,              QG = 3.26566e-15      ,
                  QB = -2.41724e-15     ,              QS = -5.19681e-16     ,             CGG = 2.87207e-15      ,             CGD = 1.51777e-18      ,
                 CGS = -2.54083e-15     ,             CGB = -3.32756e-16     ,             CBG = -3.82469e-16     ,             CBD = -1.99229e-19     ,
                 CBS = -6.0581e-16      ,             CBB = 9.88478e-16      ,             CDG = -9.89755e-16     ,             CDD = -5.24193e-19     ,
                 CDS = 1.25033e-15      ,             CDB = -2.60047e-16     ,            QBDJ = 4.7414e-16       ,            QBSJ = 5.71282e-19      ,
                CBDJ = 3.1258e-16       ,            CBSJ = 3.56319e-16      ,

    * ----------------------------------------------------------------------
    * (R) Resistors
    * ----------------------------------------------------------------------

We see that now all the transistors are biased in saturation and that the quiescent output voltage $V_{outq}$ is very close to the input common-mode voltage.

$V_{outq} =$ 900.435 mV

The difference is actually the offset voltage $V_{os}$.

$V_{os} =$ −434.670 µV

We can now apply this offset voltage to the open-loop circuit and check the operating point.

    .param VDD=1.8 Vic=0.9 Vos=-434.670u Ib1=130n Ib2=2.0u
    .param CL=1p Cc=0.5p
    .param W1=2.070u L1=1.140u W2=12.000u L2=2.170u W3=0.200u L3=16.500u W4=0.200u L4=6.660u W5=0.200u L5=2.170u
    Starting Smash simulation...

    ----------------------------------------------------------------------
    -
    - SMASH (TM) release 7.6.0 (64-bit) of Jun 30 2020
    - Copyright (c) Dolphin Design, 1992-2020. All Rights Reserved.
    -
    ----------------------------------------------------------------------

    Output directory L:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Miller OTA (VS)\M2 in MI\Simulations\smash\Gain
    Parsing circuit l:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Miller OTA (VS)\M2 in MI\Simulations\smash\Gain\Miller_OTA.pat
    Loading circuit l:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Miller OTA (VS)\M2 in MI\Simulations\smash\Gain\Miller_OTA.pat
    Processing top-level
    Elaborating circuit...
    Elaborating circuit (creating devices)...
    Elaborating circuit (elaborating devices)...
    Elaborating circuit (logic)...
    Elaborating circuit (creating devices)...
    Elaborating circuit (elaborating devices)...
    Initializing...
    Searching for HZ nets: 0%
    Linking analog resolution matrix...
    Load completed.
    Operating Point
    Operating-Point analysis (trying logarithmic damping heuristics)...
    Iteration    1, residual  9.002e-01 on EINN
    Iteration    2, residual  6.699e-01 on EINN
    Iteration    3, residual  4.658e-01 on EINN
    Iteration    4, residual  2.925e-01 on EINN
    Iteration    5, residual  1.558e-01 on EINN
    Iteration    6, residual  6.186e-02 on EINN
    Iteration    7, residual  1.370e-02 on EINN
    Iteration    8, residual  5.013e-03 on VDD
    Iteration    9, residual  2.206e-03 on VDD
    Iteration   10, residual  6.037e-04 on VDD
    Iteration   11, residual  6.013e-05 on VDD
    Iteration   12, residual  6.763e-07 on VDD
    Iteration   13, residual  1.974e-07 on M2::DI
    Iteration   14, residual  5.844e-08 on M2::DI
    Iteration   15, residual  2.663e-07 on M2::DI
    Iteration   16, residual  2.207e-07 on M2::DI
    Iteration   17, residual  1.059e-07 on M2::DI
    Iteration   18, residual  5.320e-08 on M2::DI
    Iteration   19, residual  3.362e-08 on M2::DI
    Iteration   20, residual  2.639e-08 on M2::DI
    Iteration   21, residual  1.988e-08 on M2::DI
    Iteration   22, residual  1.406e-08 on M2::DI
    Iteration   23, residual  8.855e-09 on M2::DI
    Iteration   24, residual  4.337e-09 on M2::DI
    Iteration   25, residual  1.144e-09 on M2::DI
    Iteration   26, residual  6.377e-11 on M2::DI
    Iteration   27, residual  1.124e-13 on M2::DI

    Operating point analysis completed (converged)

    CPU Time:     1s
    Elapsed Time: 2s 868ms 662us

    Contents of the op file:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

    * ----------------------------------------------------------------------
    * Operating point information at 27 degC
    * ----------------------------------------------------------------------
    *
    * Initial state obtained by resetting everything to zero
    *
    * Convergence obtained with initial logarithmic damping heuristics
    * Number of iterations: 27
    *
    * Minimum parallel DC conductance          (.GMINDC   ): 1e-12
    * Minimum parallel transient conductance   (.GMIN     ): 1e-12
    * Minimum capacitance on analog nets       (.CAPAMIN  ): 0
    *
    * ----------------------------------------------------------------------

    * ----------------------------------------------------------------------
    * Analog nets
    * ----------------------------------------------------------------------

    Nets:

        1        =  1.2644135e+00 V.
        3        =  3.9416920e-01 V.
        4        =  1.0068456e+00 V.
        5        =  8.2257555e-01 V.
        6        =  8.3638641e-01 V.
        IC       =  9.0000000e-01 V.
        ID       = -4.3467000e-04 V.
        INN      =  9.0021734e-01 V.
        INP      =  8.9978267e-01 V.
        OUT      =  8.8217006e-01 V.
        VDD      =  1.8000000e+00 V.

    Spice internal nets:

        M1A::DI  =  1.0068382e+00 V.
        M1A::SI  =  3.9417659e-01 V.
        M1B::DI  =  1.2644062e+00 V.
        M1B::SI  =  3.9417658e-01 V.
        M2::DI   =  8.8224927e-01 V.
        M2::SI   =  1.7999208e+00 V.
        M3A::DI  =  8.2244501e-01 V.
        M3A::SI  =  1.3054352e-04 V.
        M3B::DI  =  3.9403889e-01 V.
        M3B::SI  =  1.3031591e-04 V.
        M4A::DI  =  1.0070895e+00 V.
        M4A::SI  =  1.7997561e+00 V.
        M4B::DI  =  1.2646572e+00 V.
        M4B::SI  =  1.7997563e+00 V.
        M5A::DI  =  8.3538222e-01 V.
        M5A::SI  =  1.0041837e-03 V.
        M5B::DI  =  8.8116534e-01 V.
        M5B::SI  =  1.0047253e-03 V.

    Voltage sources:

        VDD   =  1.8000000e+00 V, -4.5206281e-06 A,  8.137e-06 W.
        VIC   =  9.0000000e-01 V,  0.0000000e+00 A,  0.000e+00 W.
        VID   = -4.3467000e-04 V,  0.0000000e+00 A,  0.000e+00 W.
        EINP  = -2.1733500e-04 V,  0.0000000e+00 A,  0.000e+00 W.
        EINN  =  2.1733500e-04 V,  0.0000000e+00 A,  0.000e+00 W.

    Current sources:

    *   IB1  =  2.6000000e-07  A,  9.7742445e-01  V,  2.541e-07 W.
    *   IB2  =  2.0000000e-06  A,  9.6361359e-01  V,  1.927e-06 W.

    END_USE_OP_TAG

    * ----------------------------------------------------------------------
    * SPICE Dissipated power
    * ----------------------------------------------------------------------

        Total SPICE power    = 5.9643938e-06 W.

    * ----------------------------------------------------------------------
    * (C) Capacitors
    * ----------------------------------------------------------------------

    CL (DEFAULT, multiplicity = 1)
               VALUE = 1e-12            ,           POWER = 0                ,

    CC (DEFAULT, multiplicity = 1)
               VALUE = 5e-13            ,           POWER = 0                ,

    * ----------------------------------------------------------------------
    * (M) Mos transistors
    * ----------------------------------------------------------------------

    OFF:    0
    SUB:    2
    LIN:    0
    SAT:    7

    M1A (NMOS, type NMOS, model EKV 2.6, region SUB (saturation - weak inversion), multiplicity = 1):
      Vds  =  6.12662e-01,  Vgs  =  5.06041e-01,  Vbs  = -3.94177e-01
                WEFF = 2.109e-06        ,            LEFF = 1.064e-06        ,           POWER = 7.95447e-08      ,              ID = 1.29829e-07      ,
                  GM = 3.69239e-06      ,             GDS = 6.24388e-09      ,            GMBS = 8.85838e-07      ,           VDSAT = 0.1198           ,
                 VTH = 0.579343         ,          DELVTO = 0               D,              QD = -1.93397e-17     ,              QG = 1.18039e-14      ,
                  QB = -1.17467e-14     ,              QS = -3.78602e-17     ,             CGG = 4.89057e-15      ,             CGD = 5.01038e-18      ,
                 CGS = -1.5455e-15      ,             CGB = -3.35008e-15     ,             CBG = -3.34165e-15     ,             CBD = -3.41475e-18     ,
                 CBS = -3.67725e-16     ,             CBB = 3.71279e-15      ,             CDG = -5.30459e-16     ,             CDD = -5.46456e-19     ,
                 CDS = 6.55205e-16      ,             CDB = -1.242e-16       ,            QBDJ = 2.68574e-15      ,            QBSJ = 1.11282e-15      ,
                CBDJ = 1.54325e-15      ,            CBSJ = 1.69056e-15      ,

    M1B (NMOS, type NMOS, model EKV 2.6, region SUB (saturation - weak inversion), multiplicity = 1):
      Vds  =  8.70230e-01,  Vgs  =  5.05606e-01,  Vbs  = -3.94177e-01
                WEFF = 2.109e-06        ,            LEFF = 1.064e-06        ,           POWER = 1.12888e-07      ,              ID = 1.29717e-07      ,
                  GM = 3.69102e-06      ,             GDS = 5.40936e-09      ,            GMBS = 8.85413e-07      ,           VDSAT = 0.119759         ,
                 VTH = 0.57908          ,          DELVTO = 0               D,              QD = -1.92458e-17     ,              QG = 1.1803e-14       ,
                  QB = -1.17461e-14     ,              QS = -3.768e-17       ,             CGG = 4.88586e-15      ,             CGD = 4.71166e-18      ,
                 CGS = -1.53904e-15     ,             CGB = -3.35154e-15     ,             CBG = -3.34328e-15     ,             CBD = -3.21585e-18     ,
                 CBS = -3.6623e-16      ,             CBB = 3.71272e-15      ,             CDG = -5.28229e-16     ,             CDD = -5.12214e-19     ,
                 CDS = 6.52406e-16      ,             CDB = -1.23665e-16     ,            QBDJ = 3.31098e-15      ,            QBSJ = 1.11282e-15      ,
                CBDJ = 1.50147e-15      ,            CBSJ = 1.69056e-15      ,

    M2 (PMOS, type PMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  = -9.17672e-01,  Vgs  = -5.35507e-01,  Vbs  =  7.92064e-05
                WEFF = 1.2054e-05       ,            LEFF = 2.098e-06        ,           POWER = 1.83665e-06      ,              ID = -2.00108e-06     ,
                  GM = 2.83834e-05      ,             GDS = 2.14749e-08      ,            GMBS = 9.4972e-06       ,           VDSAT = -0.178313        ,
                 VTH = -0.46901         ,          DELVTO = 0               D,              QD = 3.16128e-15      ,              QG = -1.39135e-13     ,
                  QB = 1.3047e-13       ,              QS = 5.50419e-15      ,             CGG = 1.18857e-13      ,             CGD = 2.81051e-17      ,
                 CGS = -9.02182e-14     ,             CGB = -2.86667e-14     ,             CBG = -2.94901e-14     ,             CBD = -6.89984e-18     ,
                 CBS = -2.69041e-14     ,             CBB = 5.64011e-14      ,             CDG = -3.4021e-14      ,             CDD = -8.07261e-18     ,
                 CDS = 4.45721e-14      ,             CDB = -1.05431e-14     ,            QBDJ = -1.01164e-14     ,            QBSJ = -1.02378e-18     ,
                CBDJ = 8.65761e-15      ,            CBSJ = 1.15843e-14      ,

    M3A (NMOS, type NMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  =  8.22314e-01,  Vgs  =  8.22445e-01,  Vbs  = -1.30544e-04
                WEFF = 2.39e-07         ,            LEFF = 1.6424e-05       ,           POWER = 2.1387e-07       ,              ID = 2.59998e-07      ,
                  GM = 1.28689e-06      ,             GDS = 4.18347e-10      ,            GMBS = 3.72401e-07      ,           VDSAT = 0.380543         ,
                 VTH = 0.457155         ,          DELVTO = 0               D,              QD = -2.57372e-15     ,              QG = 2.55927e-14      ,
                  QB = -1.89501e-14     ,              QS = -4.06885e-15     ,             CGG = 2.25034e-14      ,             CGD = 1.5471e-18       ,
                 CGS = -1.99392e-14     ,             CGB = -2.56579e-15     ,             CBG = -2.99868e-15     ,             CBD = -2.03217e-19     ,
                 CBS = -4.75136e-15     ,             CBB = 7.75024e-15      ,             CDG = -7.75406e-15     ,             CDD = -5.34254e-19     ,
                 CDS = 9.81064e-15      ,             CDB = -2.05605e-15     ,            QBDJ = 4.35614e-16      ,            QBSJ = 7.4219e-20       ,
                CBDJ = 3.14865e-16      ,            CBSJ = 3.56396e-16      ,

    M3B (NMOS, type NMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  =  3.93909e-01,  Vgs  =  8.22445e-01,  Vbs  = -1.30316e-04
                WEFF = 2.39e-07         ,            LEFF = 1.6424e-05       ,           POWER = 1.02305e-07      ,              ID = 2.59545e-07      ,
                  GM = 1.27928e-06      ,             GDS = 8.5421e-09       ,            GMBS = 3.70468e-07      ,           VDSAT = 0.38052          ,
                 VTH = 0.457183         ,          DELVTO = 0               D,              QD = -2.57716e-15     ,              QG = 2.55958e-14      ,
                  QB = -1.89491e-14     ,              QS = -4.06956e-15     ,             CGG = 2.26111e-14      ,             CGD = -1.43149e-16     ,
                 CGS = -1.99281e-14     ,             CGB = -2.53988e-15     ,             CBG = -2.97322e-15     ,             CBD = -3.47599e-17     ,
                 CBS = -4.74877e-15     ,             CBB = 7.75674e-15      ,             CDG = -7.85754e-15     ,             CDD = 1.3828e-16       ,
                 CDS = 9.80047e-15      ,             CDB = -2.08121e-15     ,            QBDJ = 2.15279e-16      ,            QBSJ = 7.40896e-20      ,
                CBDJ = 3.31145e-16      ,            CBSJ = 3.56396e-16      ,

    M4A (PMOS, type PMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  = -7.92667e-01,  Vgs  = -7.92910e-01,  Vbs  =  2.43875e-04
                WEFF = 2.54e-07         ,            LEFF = 6.588e-06        ,           POWER = 1.02976e-07      ,              ID = -1.29829e-07     ,
                  GM = 6.88183e-07      ,             GDS = 4.06301e-10      ,            GMBS = 2.42777e-07      ,           VDSAT = -0.350571        ,
                 VTH = -0.460859        ,          DELVTO = 0               D,              QD = 9.83997e-16      ,              QG = -1.16058e-14     ,
                  QB = 9.05725e-15      ,              QS = 1.56457e-15      ,             CGG = 9.62134e-15      ,             CGD = 8.20792e-19      ,
                 CGS = -8.37967e-15     ,             CGB = -1.24249e-15     ,             CBG = -1.42537e-15     ,             CBD = -1.20124e-19     ,
                 CBS = -2.282e-15       ,             CBB = 3.70749e-15      ,             CDG = -3.25361e-15     ,             CDD = -2.78147e-19     ,
                 CDS = 4.23006e-15      ,             CDB = -9.76176e-16     ,            QBDJ = -3.38967e-16     ,            QBSJ = -1.19288e-19     ,
                CBDJ = 3.41998e-16      ,            CBSJ = 4.38362e-16      ,

    M4B (PMOS, type PMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  = -5.35099e-01,  Vgs  = -7.92911e-01,  Vbs  =  2.43666e-04
                WEFF = 2.54e-07         ,            LEFF = 6.588e-06        ,           POWER = 6.94756e-08      ,              ID = -1.29718e-07     ,
                  GM = 6.87593e-07      ,             GDS = 4.64242e-10      ,            GMBS = 2.42573e-07      ,           VDSAT = -0.350555        ,
                 VTH = -0.460879        ,          DELVTO = 0               D,              QD = 9.83926e-16      ,              QG = -1.16056e-14     ,
                  QB = 9.05722e-15      ,              QS = 1.56446e-15      ,             CGG = 9.62128e-15      ,             CGD = 8.03966e-19      ,
                 CGS = -8.37959e-15     ,             CGB = -1.24249e-15     ,             CBG = -1.42535e-15     ,             CBD = -1.52408e-19     ,
                 CBS = -2.282e-15       ,             CBB = 3.7075e-15       ,             CDG = -3.25361e-15     ,             CDD = -2.19029e-19     ,
                 CDS = 4.23002e-15      ,             CDB = -9.76188e-16     ,            QBDJ = -2.37522e-16     ,            QBSJ = -1.19185e-19     ,
                CBDJ = 3.64876e-16      ,            CBSJ = 4.38362e-16      ,

    M5A (NMOS, type NMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  =  8.34378e-01,  Vgs  =  8.35382e-01,  Vbs  = -1.00418e-03
                WEFF = 2.39e-07         ,            LEFF = 2.094e-06        ,           POWER = 1.67277e-06      ,              ID = 2e-06            ,
                  GM = 9.71543e-06      ,             GDS = 2.43046e-08      ,            GMBS = 2.79676e-06      ,           VDSAT = 0.376849         ,
                 VTH = 0.469882         ,          DELVTO = 0               D,              QD = -3.28713e-16     ,              QG = 3.26557e-15      ,
                  QB = -2.41722e-15     ,              QS = -5.19631e-16     ,             CGG = 2.87202e-15      ,             CGD = 1.544e-18        ,
                 CGS = -2.54081e-15     ,             CGB = -3.32759e-16     ,             CBG = -3.82469e-16     ,             CBD = -2.02676e-19     ,
                 CBS = -6.0581e-16      ,             CBB = 9.88482e-16      ,             CDG = -9.89735e-16     ,             CDD = -5.3325e-19      ,
                 CDS = 1.25031e-15      ,             CDB = -2.60047e-16     ,            QBDJ = 4.42108e-16      ,            QBSJ = 5.70856e-19      ,
                CBDJ = 3.1447e-16       ,            CBSJ = 3.56319e-16      ,

    M5B (NMOS, type NMOS, model EKV 2.6, region SAT (saturation - strong inversion), multiplicity = 1):
      Vds  =  8.80161e-01,  Vgs  =  8.35382e-01,  Vbs  = -1.00473e-03
                WEFF = 2.39e-07         ,            LEFF = 2.094e-06        ,           POWER = 1.76529e-06      ,              ID = 2.00108e-06      ,
                  GM = 9.7209e-06       ,             GDS = 2.31391e-08      ,            GMBS = 2.79827e-06      ,           VDSAT = 0.376866         ,
                 VTH = 0.469861         ,          DELVTO = 0               D,              QD = -3.28737e-16     ,              QG = 3.26564e-15      ,
                  QB = -2.41723e-15     ,              QS = -5.19667e-16     ,             CGG = 2.87206e-15      ,             CGD = 1.52511e-18      ,
                 CGS = -2.54083e-15     ,             CGB = -3.32757e-16     ,             CBG = -3.82469e-16     ,             CBD = -2.00194e-19     ,
                 CBS = -6.0581e-16      ,             CBB = 9.88479e-16      ,             CDG = -9.8975e-16      ,             CDD = -5.26729e-19     ,
                 CDS = 1.25032e-15      ,             CDB = -2.60047e-16     ,            QBDJ = 4.65025e-16      ,            QBSJ = 5.71164e-19      ,
                CBDJ = 3.13109e-16      ,            CBSJ = 3.56319e-16      ,

    * ----------------------------------------------------------------------
    * (R) Resistors
    * ----------------------------------------------------------------------

We see that now all the transistors are biased in saturation and that the quiescent output voltage $V_{outq}$ is close to the input common-mode voltage.

$V_{outq} =$ 882.170 mV

## Large-signal differential transfer characteristic¶

In order to simulate the small-signal diferential open-loop gain we first need to check the differential transfer characteristic in order to find the eventual offset voltage that needs to be added to make sure the output voltage is set at the common-mode voltage.

    .param Vidmin=-9.000e-01 Vidmax=9.000e-01 dVid=2.000e-03
    Starting Smash simulation...

    ----------------------------------------------------------------------
    -
    - SMASH (TM) release 7.6.0 (64-bit) of Jun 30 2020
    - Copyright (c) Dolphin Design, 1992-2020. All Rights Reserved.
    -
    ----------------------------------------------------------------------

    Output directory L:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Miller OTA (VS)\M2 in MI\Simulations\smash\Gain
    Parsing circuit l:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Miller OTA (VS)\M2 in MI\Simulations\smash\Gain\Miller_OTA.pat
    Loading circuit l:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Miller OTA (VS)\M2 in MI\Simulations\smash\Gain\Miller_OTA.pat
    Processing top-level
    Elaborating circuit...
    Elaborating circuit (creating devices)...
    Elaborating circuit (elaborating devices)...
    Elaborating circuit (logic)...
    Elaborating circuit (creating devices)...
    Elaborating circuit (elaborating devices)...
    Initializing...
    Searching for HZ nets: 0%
    Linking analog resolution matrix...
    Load completed.
    DC Transfer - VID.Value
    Operating-Point analysis (trying logarithmic damping heuristics)...
    Number of iterations:   0
    DC transfer analysis completed
    Launch Measurements: 12
    End Measurements

    CPU Time:     1s 187ms 500us
    Elapsed Time: 5s 446ms 716us

    VDD = 1.8 V
    Vic = 0.9 V
    Voutq = 0.882 V
    Voutmax = 1.795 V
    Voutmin = 0.000 V
    Vswing = 1.795 V

We can zoom into the high gain region to extract a more accurate value of the offset voltage that is needed to bring the output voltage back to the input common-mode voltage $V_{ic}$.

    .param Vidmin=-4.400e-04 Vidmax=-4.300e-04 dVid=2.000e-08
    Starting Smash simulation...

    ----------------------------------------------------------------------
    -
    - SMASH (TM) release 7.6.0 (64-bit) of Jun 30 2020
    - Copyright (c) Dolphin Design, 1992-2020. All Rights Reserved.
    -
    ----------------------------------------------------------------------

    Output directory L:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Miller OTA (VS)\M2 in MI\Simulations\smash\Gain
    Parsing circuit l:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Miller OTA (VS)\M2 in MI\Simulations\smash\Gain\Miller_OTA.pat
    Loading circuit l:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Miller OTA (VS)\M2 in MI\Simulations\smash\Gain\Miller_OTA.pat
    Processing top-level
    Elaborating circuit...
    Elaborating circuit (creating devices)...
    Elaborating circuit (elaborating devices)...
    Elaborating circuit (logic)...
    Elaborating circuit (creating devices)...
    Elaborating circuit (elaborating devices)...
    Initializing...
    Searching for HZ nets: 0%
    Linking analog resolution matrix...
    Load completed.
    DC Transfer - VID.Value
    Operating-Point analysis (trying logarithmic damping heuristics)...
    Number of iterations:   0
    DC transfer analysis completed
    Launch Measurements: 12
    End Measurements

    CPU Time:     875ms
    Elapsed Time: 3s 730ms 722us

    VDD = 1.8 V
    Vic = 0.9 V
    Voutq = 0.882 V
    Vos = -434.630 uV
    Voutmax = 1.669 V
    Voutmin = 0.283 V
    Vswing = 1.386 V

Having extracted a more accurate value of the offset voltage, we save it for further AC simulation.

    .param VDD=1.8 Vic=0.9 Vos=-434.630u Ib1=130n Ib2=2.0u
    .param CL=1p Cc=0.5p
    .param W1=2.070u L1=1.140u W2=12.000u L2=2.170u W3=0.200u L3=16.500u W4=0.200u L4=6.660u W5=0.200u L5=2.170u

## Open-loop gain¶

### From closed-loop gain simulation¶

In Smash it is unfortunately not possible to export the complex value of the closed-loop gain in batch mode simulation. We can verify this approach using the Smash interface.

### From open-loop simulation¶

Having extracted the offset voltage to make sure that the output voltage is close to the input common-mode voltage, we can now simulate the open-loop gain.

    Starting Smash simulation...

    ----------------------------------------------------------------------
    -
    - SMASH (TM) release 7.6.0 (64-bit) of Jun 30 2020
    - Copyright (c) Dolphin Design, 1992-2020. All Rights Reserved.
    -
    ----------------------------------------------------------------------

    Output directory L:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Miller OTA (VS)\M2 in MI\Simulations\smash\Gain
    Parsing circuit l:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Miller OTA (VS)\M2 in MI\Simulations\smash\Gain\Miller_OTA.pat
    Loading circuit l:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Miller OTA (VS)\M2 in MI\Simulations\smash\Gain\Miller_OTA.pat
    Processing top-level
    Elaborating circuit...
    Elaborating circuit (creating devices)...
    Elaborating circuit (elaborating devices)...
    Elaborating circuit (logic)...
    Elaborating circuit (creating devices)...
    Elaborating circuit (elaborating devices)...
    Initializing...
    Searching for HZ nets: 0%
    Linking analog resolution matrix...
    Load completed.
    Operating-Point analysis (trying logarithmic damping heuristics)...
    Iteration    1, residual  9.002e-01 on EINN
    Iteration    2, residual  6.699e-01 on EINN
    Iteration    3, residual  4.658e-01 on EINN
    Iteration    4, residual  2.925e-01 on EINN
    Iteration    5, residual  1.558e-01 on EINN
    Iteration    6, residual  6.186e-02 on EINN
    Iteration    7, residual  1.370e-02 on EINN
    Iteration    8, residual  5.013e-03 on VDD
    Iteration    9, residual  2.206e-03 on VDD
    Iteration   10, residual  6.037e-04 on VDD
    Iteration   11, residual  6.013e-05 on VDD
    Iteration   12, residual  6.763e-07 on VDD
    Iteration   13, residual  1.974e-07 on M2::DI
    Iteration   14, residual  5.839e-08 on M2::DI
    Iteration   15, residual  2.661e-07 on M2::DI
    Iteration   16, residual  2.204e-07 on M2::DI
    Iteration   17, residual  1.056e-07 on M2::DI
    Iteration   18, residual  5.279e-08 on M2::DI
    Iteration   19, residual  3.309e-08 on M2::DI
    Iteration   20, residual  2.584e-08 on M2::DI
    Iteration   21, residual  1.938e-08 on M2::DI
    Iteration   22, residual  1.361e-08 on M2::DI
    Iteration   23, residual  8.476e-09 on M2::DI
    Iteration   24, residual  4.061e-09 on M2::DI
    Iteration   25, residual  1.019e-09 on M2::DI
    Iteration   26, residual  5.074e-11 on M2::DI
    Iteration   27, residual  7.091e-14 on M2::DI

    Operating point analysis completed (converged)
    Small Signal
    Small signal analysis completed
    Launch Measurements: 12
    End Measurements

    CPU Time:     1s 140ms 625us
    Elapsed Time: 5s 829ms 261us

    Adc = 112.090 dB
    GBW = 1.093e+06 Hz
    Phase at GBW = -121.850 deg
    Phase margin = 58.152 deg

We can observe a very good match between the small-signal simulations and the theoretical results of the $GBW$. The DC gain obtained from the simulations is significantly larger than that obtained from the theoretical estimation. This is due to the simplistic model of the output conductance. However it is not a problem since the simulated gain is larger than the specifications. The phase margin spec is slightly lower than the specs.

The DC gain could be decreased by reducing the length of transistors M1a-M1b, M2, M4a-M4b and M5a-M5b. This will also reduce the transistors area and parasitic capacitances and therefore increase the phase margin.

## Input-referred noise¶

We can compare the theoretical input-referred noise to that obtained from simulations.

    Starting Smash simulation...

    ----------------------------------------------------------------------
    -
    - SMASH (TM) release 7.6.0 (64-bit) of Jun 30 2020
    - Copyright (c) Dolphin Design, 1992-2020. All Rights Reserved.
    -
    ----------------------------------------------------------------------

    Output directory L:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Simple OTA (VS)\Trade-off\Simulations\smash\Gain
    Parsing circuit l:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Simple OTA (VS)\Trade-off\Simulations\smash\Gain\Miller_OTA.pat
    Loading circuit l:\My Drive\Lectures\Master\Fundamentals of Analog VLSI Design\2024\Jupyter Notebooks\Miller OTA\Simple OTA (VS)\Trade-off\Simulations\smash\Gain\Miller_OTA.pat
    Processing top-level
    Elaborating circuit...
    Elaborating circuit (creating devices)...
    Elaborating circuit (elaborating devices)...
    Elaborating circuit (logic)...
    Elaborating circuit (creating devices)...
    Elaborating circuit (elaborating devices)...
    Initializing...
    Searching for HZ nets: 0%
    Linking analog resolution matrix...
    Load completed.
    Operating-Point analysis (trying logarithmic damping heuristics)...
    Iteration    1, residual  9.000e-01 on EINP
    Iteration    2, residual  6.698e-01 on EINP
    Iteration    3, residual  4.657e-01 on EINP
    Iteration    4, residual  2.924e-01 on EINP
    Iteration    5, residual  1.557e-01 on EINP
    Iteration    6, residual  6.181e-02 on EINP
    Iteration    7, residual  1.368e-02 on EINP
    Iteration    8, residual  3.158e-03 on VDD
    Iteration    9, residual  1.389e-03 on VDD
    Iteration   10, residual  3.798e-04 on VDD
    Iteration   11, residual  3.777e-05 on VDD
    Iteration   12, residual  6.925e-07 on M5B::SI
    Iteration   13, residual  2.593e-07 on M5B::SI
    Iteration   14, residual  2.013e-07 on M5B::SI
    Iteration   15, residual  1.090e-07 on M5B::SI
    Iteration   16, residual  5.097e-08 on M5B::SI
    Iteration   17, residual  2.819e-08 on M5B::SI
    Iteration   18, residual  1.893e-08 on M5B::SI
    Iteration   19, residual  1.046e-08 on M5B::DI
    Iteration   20, residual  6.085e-09 on M5B::DI
    Iteration   21, residual  2.898e-09 on M5B::DI
    Iteration   22, residual  8.775e-10 on M5B::DI
    Iteration   23, residual  8.724e-11 on M5B::DI
    Iteration   24, residual  6.525e-13 on M5B::DI
    Iteration   25, residual  3.216e-17 on EINP

    Operating point analysis completed (converged)
    Noise
    Noise analysis completed
    Launch Measurements: 12
    End Measurements

    CPU Time:     2s 93ms 750us
    Elapsed Time: 3s 122ms 694us

We can observe an excellent match between the noise simulations and the theoretical results except at frequencies above the $GBW$. This is simply due to the fact that the noise coming from M4a-M4b, M2 and M5a-M5b was referred to the input by simply dividing by the square of the DC gain instead of the square magnitude of the frequency-dependent gain.

We can analyze the individual contributions of the various transistors.

## Input-referred offset voltage¶

The standard deviation of the random input-referred offset voltage can be simulated in Smash using Monte-Carlo (MC) simulation with 1000 runs. Note that the matching parameters have to be converted to dispersion parameters according to \begin{align*} SIGMAV &= \frac{A_{VT}}{\sqrt{2}},\\ SIGMAI &= \frac{A_{\beta}}{\sqrt{2}}. \end{align*} for both NMOS and pMOS.

MC simulation of the open-loop transfer characteristic for extracting the offset voltage.

The offset voltage is first extracted from the open-loop circuit as shown in the above figure. The results of the MC simulation is $\sigma_{Vos} = 4.08\,mV$ which is consistent with the dispersion simulation $\sigma_{Vos} = 4.1\,mV$ provided by Smash and close to the theoretical estimations $\sigma_{Vos} = 4\,mV$.

MC simulation using a closed-loop configuration for extracting the offset voltage.

For high gain amplifiers, it is also possible to measure the offset by putting the OPAMP in a closed loop as shown in the above figure. The results of the MC simulation is $\sigma_{Vos} = 4.07\,mV$ which is consistent with the dispersion simulation $\sigma_{Vos} = 4.1\,mV$ provided by Smash and close to the theoretical estimations $\sigma_{Vos} = 4\,mV$.

MC closed-loop simulation of the contributions of the differential pair and the current mirror to the input-referred offset.

The contributions of the various transistors to the input-referred offset is shown in the above figure. It confirms that the differential is the dominant contributor to the offset voltage.

## Power consumption¶

The total power consumption is given by

    Itot = 1.360 µA
    P = 2.448 µW

We can compare the current and power consumption of the Miller OTA to the telescopic OTAb

The current and power consumption of the Miller OTA is 1.36 times larger than that of the telescopic OTA for the same specifications and performance.

# Simulation results from ngspice¶

The theoretical results can also be compared with results obtained from simulations performed with ngspice. The cells below will run the simulations with ngspice. In order to run the simulations you need to have ngspice installed. Please refer to the moodel site for full instructions.

## Saving parameter file¶

We first write the parameter file for this specific design for running the ngspice simulations.

    .param VDD=1.8 Vic=0.9 Vos=0.000u Ib1=130n Ib2=2.0u
    .param CL=1p Cc=0.5p
    .param W1=2.070u L1=1.140u W2=12.000u L2=2.170u W3=0.200u L3=16.500u W4=0.200u L4=6.660u W5=0.200u L5=2.170u

## Operating point¶

To start we need to check the quiescent voltages and currents and the operating points of all transistors by running a .OP simulation.

    Starting ngspice simulation...

    Simulation executed successfully.

    ******
    ** ngspice-43 : Circuit level simulation program
    ** Compiled with KLU Direct Linear Solver
    ** The U. C. Berkeley CAD Group
    ** Copyright 1985-1994, Regents of the University of California.
    ** Copyright 2001-2024, The ngspice team.
    ** Please get your ngspice manual from https://ngspice.sourceforge.io/docs.html
    ** Please file your bug-reports at https://ngspice.sourceforge.io/bugrep.html
    ** Creation Date: Jul 13 2024   10:19:33
    ******

    Batch mode

    Comments and warnings go to log-file: ./Simulations/ngspice/Gain/Miller_OTA.op.log

    Contents of the log file:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

    Using SPARSE 1.3 as Direct Linear Solver
    Note: Starting dynamic gmin stepping
    Note: Dynamic gmin stepping completed
    wrdata: too few args.

    Note: No compatibility mode selected!

    Circuit: simulation of the miller ota designed with the ekv 2.6 model

    Doing analysis at TEMP = 27.000000 and TNOM = 27.000000

    No. of Data Rows : 1

    Node data saved to file ./Simulations/ngspice/Gain/miller_ota.op.ic
    Note: Simulation executed from .control section

The voltages at the various circuit nodes are given below.

| Voltage
--- | ---
vdd | 1.800
id | 0.000
ic | 0.900
inp | 0.900
inn | 0.900
out | 1.785
1 | 1.007
3 | 0.394
4 | 1.007
5 | 0.823
6 | 0.837

The output voltage is almost saturated to $V_{DD}$, pushing M2 out of saturation.

We can extract the differential input voltage that needs to be applied at the input to bring the output in the high gain region setting it for example at the input common-mode $V_{ic}=0.9\,V$. This can be done by connecting the OTA in a voltage follower mode. The input-referred offset voltage can be extracted from the closed-loop voltage follower circuit as \begin{equation*} V_{os} = V_{in} - \left(1+\frac{1}{A}\right) \cdot V_{out} \cong V_{in} - V_{out} \quad \textsf{for $A \gg 1$}, \end{equation*} where $A \triangleq A_{open\textsf{-}loop}(0)$ is the open-loop DC gain which can be assumed to be much larger than 1. This means that, provided the DC open-loop gain is sufficiently large, the offset voltage can be measured at the amplifier differential input after imposing the proper input common-mode voltage $V_{ic}$.

We can now simulate the OTA in closed-loop as a voltage follower.

    .param VDD=1.8 Vic=0.9 Ib1=130n Ib2=2.0u
    .param CL=1p Cc=0.5p
    .param W1=2.070u L1=1.140u W2=12.000u L2=2.170u W3=0.200u L3=16.500u W4=0.200u L4=6.660u W5=0.200u L5=2.170u
    Starting ngspice simulation...

    Simulation executed successfully.

    ******
    ** ngspice-43 : Circuit level simulation program
    ** Compiled with KLU Direct Linear Solver
    ** The U. C. Berkeley CAD Group
    ** Copyright 1985-1994, Regents of the University of California.
    ** Copyright 2001-2024, The ngspice team.
    ** Please get your ngspice manual from https://ngspice.sourceforge.io/docs.html
    ** Please file your bug-reports at https://ngspice.sourceforge.io/bugrep.html
    ** Creation Date: Jul 13 2024   10:19:33
    ******

    Batch mode

    Comments and warnings go to log-file: ./Simulations/ngspice/Follower/Miller_OTA.op.log

    Contents of the log file:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

    Using SPARSE 1.3 as Direct Linear Solver
    Note: Starting dynamic gmin stepping
    Note: Dynamic gmin stepping completed
    wrdata: too few args.

    Note: No compatibility mode selected!

    Circuit: simulation of the miller ota designed with the ekv 2.6 model

    Doing analysis at TEMP = 27.000000 and TNOM = 27.000000

    No. of Data Rows : 1

    Node data saved to file ./Simulations/ngspice/Follower/miller_ota.op.ic
    Note: Simulation executed from .control section

| Voltage
--- | ---
vdd | 1.800000
inp | 0.900000
out | 0.900435
1 | 1.264390
3 | 0.394354
4 | 1.006760
5 | 0.822604
6 | 0.836636

We see that now the ouput voltage is very close to the input voltage that has been set to $V_{ic}$. We can then extract the corresponding offset voltage $V_{os} \cong V_{in} - V_{out}$

$V_{os} =$ −435.000 µV

We can now apply this offset voltage to the open-loop operating point point simulation.

    .param VDD=1.8 Vic=0.9 Vos=-435.000u Ib1=130n Ib2=2.0u
    .param CL=1p Cc=0.5p
    .param W1=2.070u L1=1.140u W2=12.000u L2=2.170u W3=0.200u L3=16.500u W4=0.200u L4=6.660u W5=0.200u L5=2.170u

    Starting ngspice simulation...

    Simulation executed successfully.

    ******
    ** ngspice-43 : Circuit level simulation program
    ** Compiled with KLU Direct Linear Solver
    ** The U. C. Berkeley CAD Group
    ** Copyright 1985-1994, Regents of the University of California.
    ** Copyright 2001-2024, The ngspice team.
    ** Please get your ngspice manual from https://ngspice.sourceforge.io/docs.html
    ** Please file your bug-reports at https://ngspice.sourceforge.io/bugrep.html
    ** Creation Date: Jul 13 2024   10:19:33
    ******

    Batch mode

    Comments and warnings go to log-file: ./Simulations/ngspice/Gain/Miller_OTA.op.log

    Contents of the log file:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

    Using SPARSE 1.3 as Direct Linear Solver
    Note: Starting dynamic gmin stepping
    Note: Dynamic gmin stepping completed
    wrdata: too few args.

    Note: No compatibility mode selected!

    Circuit: simulation of the miller ota designed with the ekv 2.6 model

    Doing analysis at TEMP = 27.000000 and TNOM = 27.000000

    No. of Data Rows : 1

    Node data saved to file ./Simulations/ngspice/Gain/miller_ota.op.ic
    Note: Simulation executed from .control section

| Voltage
--- | ---
vdd | 1.800
id | -0.000
ic | 0.900
inp | 0.900
inn | 0.900
out | 0.705
1 | 1.265
3 | 0.394
4 | 1.007
5 | 0.823
6 | 0.837

The quiescent output voltage is now in the high gain region.

The operating point information for all transistors can be extracted from the .op file.

| ID | Ispec | IC | VDsat | n | Gm | Gms | Gds | Gmb | Rn | Vnth | gamman | Vnfl at 1Hz
--- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | ---
M1a | 1.30E-07 | 1.30E-06 | 1.00E-01 | 1.20E-01 | 1.27E+00 | 3.69E-06 | 4.59E-06 | 6.25E-09 | 8.86E-07 | 1.75E+05 | 5.38E-08 | 6.45E-01 | 2.07E-05
M1b | 1.30E-07 | 1.30E-06 | 9.97E-02 | 1.20E-01 | 1.27E+00 | 3.69E-06 | 4.58E-06 | 5.41E-09 | 8.86E-07 | 1.75E+05 | 5.38E-08 | 6.44E-01 | 2.07E-05
M2 | 2.00E-06 | 9.56E-07 | 2.09E+00 | 1.78E-01 | 1.31E+00 | 2.84E-05 | 3.79E-05 | 2.01E-08 | 9.50E-06 | 2.79E+04 | 2.15E-08 | 7.93E-01 | 1.78E-05
M3a | 2.60E-07 | 9.02E-09 | 2.89E+01 | 3.81E-01 | 1.27E+00 | 1.29E-06 | 1.66E-06 | 4.19E-10 | 3.73E-07 | 6.62E+05 | 1.05E-07 | 8.53E-01 | 1.56E-05
M3b | 2.60E-07 | 9.01E-09 | 2.88E+01 | 3.81E-01 | 1.27E+00 | 1.28E-06 | 1.66E-06 | 8.51E-09 | 3.71E-07 | 6.70E+05 | 1.05E-07 | 8.58E-01 | 1.56E-05
M4a | 1.30E-07 | 5.68E-09 | 2.29E+01 | 3.51E-01 | 1.31E+00 | 6.89E-07 | 9.32E-07 | 4.07E-10 | 2.43E-07 | 1.28E+06 | 1.46E-07 | 8.81E-01 | 6.91E-05
M4b | 1.30E-07 | 5.68E-09 | 2.29E+01 | 3.51E-01 | 1.31E+00 | 6.88E-07 | 9.32E-07 | 4.65E-10 | 2.43E-07 | 1.28E+06 | 1.46E-07 | 8.81E-01 | 6.91E-05
M5a | 2.00E-06 | 6.93E-08 | 2.91E+01 | 3.83E-01 | 1.27E+00 | 9.75E-06 | 1.26E-05 | 2.44E-08 | 2.81E-06 | 8.91E+04 | 3.84E-08 | 8.69E-01 | 4.37E-05
M5b | 2.00E-06 | 6.92E-08 | 2.91E+01 | 3.83E-01 | 1.27E+00 | 9.73E-06 | 1.26E-05 | 2.88E-08 | 2.80E-06 | 8.93E+04 | 3.85E-08 | 8.69E-01 | 4.37E-05

We can check the bias voltages and operating region of each transistor below.

| Type | Function | ID | IC | VG | VS | VD | VDS | VDsat | Region | Saturation
--- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | ---
M1a | n | DP | 1.298E-07 | 1.003E-01 | 8.998E-01 | 3.942E-01 | 1.007E+00 | 6.126E-01 | 1.198E-01 | MI | sat
M1b | n | DP | 1.297E-07 | 9.974E-02 | 9.002E-01 | 3.942E-01 | 1.265E+00 | 8.705E-01 | 1.198E-01 | WI | sat
M2 | p | CS | 1.997E-06 | 2.092E+00 | 5.353E-01 | 0.000E+00 | 1.095E+00 | 1.095E+00 | 1.783E-01 | MI | sat
M3a | n | CM | 2.600E-07 | 2.885E+01 | 8.226E-01 | 0.000E+00 | 8.226E-01 | 8.226E-01 | 3.813E-01 | SI | sat
M3b | n | CM | 2.595E-07 | 2.885E+01 | 8.226E-01 | 0.000E+00 | 3.942E-01 | 3.942E-01 | 3.813E-01 | SI | sat
M4a | p | CM | 1.298E-07 | 2.290E+01 | 7.932E-01 | 0.000E+00 | 7.932E-01 | 7.932E-01 | 3.510E-01 | SI | sat
M4b | p | CM | 1.297E-07 | 2.290E+01 | 7.932E-01 | 0.000E+00 | 5.353E-01 | 5.353E-01 | 3.510E-01 | SI | sat
M5a | n | CM | 2.000E-06 | 2.914E+01 | 8.366E-01 | 0.000E+00 | 8.366E-01 | 8.366E-01 | 3.827E-01 | SI | sat
M5b | n | CM | 1.997E-06 | 2.913E+01 | 8.366E-01 | 0.000E+00 | 7.049E-01 | 7.049E-01 | 3.827E-01 | SI | sat

All transistors are biased in saturation. The operating points looks fine. We can now proceed with the simulation of the open-loop large-signal transfer characteristic.

## Large-signal differential transfer characteristic¶

We now simulate the DC differential transfer characteristic. We can then check the systematic offset voltage that was extracted above.

    Starting NGSpice simulation...

    Simulation executed successfully.

    ******
    ** ngspice-43 : Circuit level simulation program
    ** Compiled with KLU Direct Linear Solver
    ** The U. C. Berkeley CAD Group
    ** Copyright 1985-1994, Regents of the University of California.
    ** Copyright 2001-2024, The ngspice team.
    ** Please get your ngspice manual from https://ngspice.sourceforge.io/docs.html
    ** Please file your bug-reports at https://ngspice.sourceforge.io/bugrep.html
    ** Creation Date: Jul 13 2024   10:19:33
    ******

    Batch mode

    Comments and warnings go to log-file: ./Simulations/ngspice/Gain/Miller_OTA.dc.log

    Contents of the log file:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

    Using SPARSE 1.3 as Direct Linear Solver
    Note: Starting dynamic gmin stepping
    Note: Dynamic gmin stepping completed
    Using SPARSE 1.3 as Direct Linear Solver
    Note: Starting dynamic gmin stepping
    Note: Dynamic gmin stepping completed

    Note: No compatibility mode selected!

    Circuit: simulation of the miller ota designed with the ekv 2.6 model

    Doing analysis at TEMP = 27.000000 and TNOM = 27.000000

    No. of Data Rows : 1
    Doing analysis at TEMP = 27.000000 and TNOM = 27.000000

    No. of Data Rows : 901
    vos                 =  -9.916165e-04
    voutmax             =  1.794839e+00 at=  9.000000e-01
    voutmin             =  1.480901e-07 at=  -9.000000e-01
    Note: Simulation executed from .control section

    VDD = 1.8 V
    Vic = 0.9 V
    Vos = -435.000 uV
    Voutq = 0.705 V
    Voutmax = 1.795 V
    Voutmin = 0.000 V
    Vswing = 1.795 V

The large-signal transfer characteristic shows a very sharp transition around $V_{id}=0$. We can now zoom into the high gain region and extract a more accurate value of the offset voltage.

    Starting NGSpice simulation...

    Simulation executed successfully.

    ******
    ** ngspice-43 : Circuit level simulation program
    ** Compiled with KLU Direct Linear Solver
    ** The U. C. Berkeley CAD Group
    ** Copyright 1985-1994, Regents of the University of California.
    ** Copyright 2001-2024, The ngspice team.
    ** Please get your ngspice manual from https://ngspice.sourceforge.io/docs.html
    ** Please file your bug-reports at https://ngspice.sourceforge.io/bugrep.html
    ** Creation Date: Jul 13 2024   10:19:33
    ******

    Batch mode

    Comments and warnings go to log-file: ./Simulations/ngspice/Gain/Miller_OTA.dc.log

    Contents of the log file:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

    Using SPARSE 1.3 as Direct Linear Solver
    Note: Starting dynamic gmin stepping
    Note: Dynamic gmin stepping completed
    Using SPARSE 1.3 as Direct Linear Solver
    Note: Starting dynamic gmin stepping
    Note: Dynamic gmin stepping completed

    Note: No compatibility mode selected!

    Circuit: simulation of the miller ota designed with the ekv 2.6 model

    Doing analysis at TEMP = 27.000000 and TNOM = 27.000000

    No. of Data Rows : 1
    Doing analysis at TEMP = 27.000000 and TNOM = 27.000000

    No. of Data Rows : 501
    vos                 =  -4.344959e-04
    voutmax             =  1.667335e+00 at=  -4.300000e-04
    voutmin             =  2.816339e-01 at=  -4.400000e-04
    Note: Simulation executed from .control section

    VDD = 1.8 V
    Vic = 0.9 V
    Vos = -434.496 uV
    Voutq = 0.705 V
    Voutmax = 1.667 V
    Voutmin = 0.282 V
    Vswing = 1.386 V

We can now save the extracted offset voltage value for further AC simulation.

    .param VDD=1.8 Vic=0.9 Vos=-434.496u Ib1=130n Ib2=2.0u
    .param CL=1p Cc=0.5p
    .param W1=2.070u L1=1.140u W2=12.000u L2=2.170u W3=0.200u L3=16.500u W4=0.200u L4=6.660u W5=0.200u L5=2.170u

## Open-loop gain¶

### Closed-loop circuit¶

Simulating the open-loop gain for high gain amplifiers is not easy to perform without closing the loop. There are basically two approaches to simulate the open-loop gain for high-gain amplifiers: 1) Imposing a DC offset voltage to the amplifier in open-loop configuration that brings the output voltage back to normal (for example equal to the input common-mode voltage) or 2) Simulating the closed-loop gain (for example in voltage follower mode with a feedback gain of 1) and extracting the open-loop gain from the closed loop gain according to \begin{equation*} A_{open\textsf{-}loop}(\omega)= \frac{A_{closed\textsf{-}loop}(\omega)}{1 - A_{closed\textsf{-}loop}(\omega)}, \end{equation*} where $A_{closed\textsf{-}loop}(\omega)$ is the simulated closed-loop transfer function and $A_{open\textsf{-}loop}(\omega)$, the computed open-loop transfer function. The above relation assumes that the open-loop DC gain is large enough for the input-referred offset voltage to be ignored.

The input-referred offset voltage can be extracted from the closed-loop voltage follower circuit as \begin{equation*} V_{os} = V_{in} - \left(1+\frac{1}{A}\right) \cdot V_{out} \cong V_{in} - V_{out} \quad \textsf{for $A \gg 1$}, \end{equation*} where $A \triangleq A_{open\textsf{-}loop}(0)$ is the open-loop DC gain which can be assumed to be much larger than 1. This means that, provided the DC open-loop gain is sufficiently large, the offset voltage can be measured at the amplifier differential input after imposing the proper input common-mode voltage $V_{ic}$.

We can now simulate the OTA in closed-loop as a voltage follower. Note that we need to have a sufficient number of digits for the simulated closed-loop gain because the later is very close to 1.

    Starting NGSpice simulation...

    Simulation executed successfully.

    ******
    ** ngspice-43 : Circuit level simulation program
    ** Compiled with KLU Direct Linear Solver
    ** The U. C. Berkeley CAD Group
    ** Copyright 1985-1994, Regents of the University of California.
    ** Copyright 2001-2024, The ngspice team.
    ** Please get your ngspice manual from https://ngspice.sourceforge.io/docs.html
    ** Please file your bug-reports at https://ngspice.sourceforge.io/bugrep.html
    ** Creation Date: Jul 13 2024   10:19:33
    ******

    Batch mode

    Comments and warnings go to log-file: ./Simulations/ngspice/Follower/Miller_OTA.ac.log

    Contents of the log file:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

    Using SPARSE 1.3 as Direct Linear Solver
    Note: Starting dynamic gmin stepping
    Note: Dynamic gmin stepping completed
    Using SPARSE 1.3 as Direct Linear Solver
    Note: Starting dynamic gmin stepping
    Note: Dynamic gmin stepping completed
    Error: no such vector as aphdeg.

    Note: No compatibility mode selected!

    Circuit: simulation of the miller ota designed with the ekv 2.6 model

    Doing analysis at TEMP = 27.000000 and TNOM = 27.000000

    No. of Data Rows : 1
    ASCII raw file "./Simulations/ngspice/Follower/Miller_OTA.ac.op"
    Doing analysis at TEMP = 27.000000 and TNOM = 27.000000

    No. of Data Rows : 370
    fc                  =  0.000000e+00
    Note: Simulation executed from .control section

    Adc = 73.567 dB
    GBW = 1.058e+06 Hz
    Phase at GBW = -118.758 deg
    Phase margin = 61.242 deg

With this technique, the DC gain is much underestimated. This might be due to the fairly large offset voltage.

### Open-loop circuit¶

After having checked the operating point information, extracted the offset voltage and making sure that the OTA output is not saturated, we can now proceed with the open-loop gain simulation.

    Starting NGSpice simulation...

    Simulation executed successfully.

    ******
    ** ngspice-43 : Circuit level simulation program
    ** Compiled with KLU Direct Linear Solver
    ** The U. C. Berkeley CAD Group
    ** Copyright 1985-1994, Regents of the University of California.
    ** Copyright 2001-2024, The ngspice team.
    ** Please get your ngspice manual from https://ngspice.sourceforge.io/docs.html
    ** Please file your bug-reports at https://ngspice.sourceforge.io/bugrep.html
    ** Creation Date: Jul 13 2024   10:19:33
    ******

    Batch mode

    Comments and warnings go to log-file: ./Simulations/ngspice/Gain/Miller_OTA.ac.log

    Contents of the log file:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

    Using SPARSE 1.3 as Direct Linear Solver
    Note: Starting dynamic gmin stepping
    Note: Dynamic gmin stepping completed
    Using SPARSE 1.3 as Direct Linear Solver
    Note: Starting dynamic gmin stepping
    Note: Dynamic gmin stepping completed

    Note: No compatibility mode selected!

    Circuit: simulation of the symmetrical ota designed with the ekv 2.6 model

    Doing analysis at TEMP = 27.000000 and TNOM = 27.000000

    No. of Data Rows : 1
    ASCII raw file "./Simulations/ngspice/Gain/Miller_OTA.ac.op"
    Doing analysis at TEMP = 27.000000 and TNOM = 27.000000

    No. of Data Rows : 370
    adc                 =  1.121061e+02 at=  1.000000e-01
    gbw                 =  1.118728e+06
    pgbw                =  -1.202518e+02
    Note: Simulation executed from .control section

    Adc = 112.106 dB
    GBW = 1.119e+06 Hz
    Phase at GBW = -120.252 deg
    Phase margin = 59.748 deg

We can observe a very good match between the small-signal simulations and the theoretical results of the $GBW$. The DC gain obtained from the simulations is significantly larger than that obtained from the theoretical estimation. This is however not a problem since the simulated gain is larger than the specifications.

## Input-referred noise¶

We can compare the theoretical input-referred noise to that obtained from simulations.

    Starting NGSpice simulation...

    Simulation executed successfully.

    ******
    ** ngspice-43 : Circuit level simulation program
    ** Compiled with KLU Direct Linear Solver
    ** The U. C. Berkeley CAD Group
    ** Copyright 1985-1994, Regents of the University of California.
    ** Copyright 2001-2024, The ngspice team.
    ** Please get your ngspice manual from https://ngspice.sourceforge.io/docs.html
    ** Please file your bug-reports at https://ngspice.sourceforge.io/bugrep.html
    ** Creation Date: Jul 13 2024   10:19:33
    ******

    Batch mode

    Comments and warnings go to log-file: ./Simulations/ngspice/Gain/Miller_OTA.nz.log

    Contents of the log file:
    ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

    Using SPARSE 1.3 as Direct Linear Solver
    Note: Starting dynamic gmin stepping
    Note: Dynamic gmin stepping completed
    Using SPARSE 1.3 as Direct Linear Solver
    Note: Starting dynamic gmin stepping
    Note: Dynamic gmin stepping completed

    Note: No compatibility mode selected!

    Circuit: simulation of the miller ota designed with the ekv 2.6 model

    Doing analysis at TEMP = 27.000000 and TNOM = 27.000000

    No. of Data Rows : 1
    Doing analysis at TEMP = 27.000000 and TNOM = 27.000000

    No. of Data Rows : 370

    No. of Data Rows : 1
    Note: Simulation executed from .control section

We observe an almost perfect match between the predicted and simulated input-referred noise which is completely dominated by the flicker noise contribution.

## Power consumption¶

The total power consumption (without accounting for the currents flowing through M3a and M5a) is given by

    Itot = 2.260 µA
    P = 4.068 µW

We can compare the current and power consumption of the Miller OTA to the telescopic OTA.

$I_{telescopic} =$ 500.0 nA
$P_{telescopic} =$ 900.000 nW
$P_{folded}/P_{telescopic} =$ 4.5

The current and power consumption of the Miller OTA is 4.5 times larger than that of the telescopic OTA for the same specifications and performance.

# Conclusion¶

This Notebook presented the verification of the design by simulation with Smash and ngspice. The specifications are achieved at the cost of a much larger power consumption than the symmetrical OTA for the same specification on the DC gain.